Support » Plugin: User Submitted Posts » redirect log in user submit to other link

Viewing 6 replies - 1 through 6 (of 6 total)
  • Plugin Author Jeff Starr

    (@specialk)

    Hello, I am glad to help, but unable to decipher your meaning.. if you can clarify or elaborate I will try to help asap, thank you.

    ok,

    Hereis your code

    function usp_login_required_message() {

    $message = ‘<p>’. esc_html__(‘Please’, ‘usp’);
    $message .= ‘ ‘. esc_html__(‘log in’, ‘usp’) .’ ‘;
    $message .= esc_html__(‘to submit content!’, ‘usp’) .'</p>’;

    $message = apply_filters(‘usp_require_login’, $message);

    return $message;

    }`

    So if I clicked on “log in” it will go to http://www.xyz.com/wp-login.php right?

    What I want is when I click “log in” I want to go to http://www.xyz.com/register instead of http://www.xyz.com/wp-login.php

    How to do it?

    Thanks

    • This reply was modified 8 months, 2 weeks ago by  hildaaa.
    Plugin Author Jeff Starr

    (@specialk)

    I understand your question now, thanks. If you will notice the hook that is included:

    usp_require_login

    You can use that to customize the login message however is required.

    If you need more information on how to use hooks, check out the official WP guide:

    https://codex.wordpress.org/Plugin_API/Hooks

    • This reply was modified 8 months, 2 weeks ago by  Jeff Starr.

    ok, so what is the code for that? (sorry forgot to tell you that I am beginner on this php code things)

    function usp_login_required_message() {

    $message = ‘<p>’. esc_html__(‘Please’, ‘usp’);
    $message .= ‘ ‘. esc_html__(‘log in’, ‘usp’) .’ ‘;
    $message .= esc_html__(‘to submit content!’, ‘usp’) .'</p>’;

    $message = apply_filters(‘usp_require_login’, $message);

    return $message;

    }

    Plugin Author Jeff Starr

    (@specialk)

    I totally understand, here is something that should work:

    
    function shapeSpace_modify_example($value) {
    	return '<p>Please <a href="http://www.xyz.com/register">register</a> to submit content.</p>';
    }
    add_filter('usp_require_login', 'shapeSpace_modify_example');
Viewing 6 replies - 1 through 6 (of 6 total)
  • The topic ‘redirect log in user submit to other link’ is closed to new replies.