WordPress.org

Forums

When login, stay in the same page (5 posts)

  1. xionhack
    Member
    Posted 4 years ago #

    Hi. I made my own wordpress design and I have a login box. When I put the username and password it redirects me to the admin page. I want that when I put the username and password, it logs me in but keeps me in the same page. How can I do that? Thanks!

  2. ClaytonJames
    Member
    Posted 4 years ago #

    This works quite well. Very customizable. Peter's Login Redirect

  3. xionhack
    Member
    Posted 4 years ago #

    that plugin has to be configured by user and I have to set up which website to go to. The login form is in every page, I want it to no matter which page u login from, u stay in that page

  4. ClaytonJames
    Member
    Posted 4 years ago #

    This plugin still seems to work. Just tested it on 3.1 and it did what you want. It returned the user to the same page after login and logout.
    It requires no effort on your part other than activating the plugin. I've used it several times in the past. In the half-dozen login/out tests I just made, it worked fine. Can't guarantee your results will be the same.

    http://files.viper007bond.com/wordpress/fromwhereyoucame.zip

  5. caugb
    Member
    Posted 4 years ago #

    You can do it via ajax, using wp_signon($_POST) - just include in your query the fields 'user_login', 'user_password' and 'remember'.
    So, if the ajax request return true, you can do (with javascript) location.reload(); otherwise alert someting like 'authentication failed'.

Topic Closed

This topic has been closed to new replies.

About this Topic

Tags