WordPress.org

Ready to get started?Download WordPress

Forums

[Plugin: WP-UserLogin] How can I direct them to a specific page after login (3 posts)

  1. dblast
    Member
    Posted 5 years ago #

    Hi, I'd like to have my members login then go to the most current posts. The challenge is I use a static welcome page not the most recent post as my homepage.

    So first time visitors get my welcome message then register or log in then go to the current post page.

    THanks

    Dan

  2. Jerry Stephens
    Member
    Posted 5 years ago #

    If you change line 161 from this
    $form = "<form name=\"loginform\" id=\"loginform\" action=\"". $wp_url ."/wp-login.php\" method=\"post\">
    to this
    $form = "<form name=\"loginform\" id=\"loginform\" action=\"". $wp_url ."/wp-login.php&amp;redirect_to=".urlencode('[desired page]')."\" method=\"post\">

    Of course, replace [desired page] with your actual desired page. That should solve it. Thanks for this post, I'll probably look into this as an option on the next release.

  3. Jerry Stephens
    Member
    Posted 5 years ago #

    I just released an update. It's for 2.7 only, but it does solve your problem.

Topic Closed

This topic has been closed to new replies.

About this Topic