WordPress.org

Ready to get started?Download WordPress

Forums

Theme My Login
[resolved] Redirection module not sending to Referer (27 posts)

  1. AaronC
    Member
    Posted 2 years ago #

    Hi.

    The Redirection module is not working how I thought it would. I wanted it to send users to the page they were visiting before they logged in (Referer) but it seems to take them to the login page url. Technically that IS the last page they were visiting before logging in, but I don't want them to go there, I want them to go to the page they were at when they clicked on a log in link. Isn't that how it should work?

    http://wordpress.org/extend/plugins/theme-my-login/

  2. Todd
    Member
    Posted 2 years ago #

    Having issues with the redirect on login as well. Can't get the referer to work properly or the custom link. Everything re-directs to the site home page, which I'm assuming is because the referer is sending the user to the dashboard. I've disabled the dashboard using roles and capabilities in function.php which kicks all non-authorized users to the home page.

    The rule in functions.php wouldn't get triggered if the referer or custom link worked properly.

  3. trinzia
    Member
    Posted 2 years ago #

    I also have some trouble.

    When custom was enabled, it did not redirect there. Then using the Back button in browser went to Profile, even though I hadn't been there.

  4. Jeff Farthing
    Member
    Plugin Author

    Posted 2 years ago #

    I suggest you all disable all other plugins and see if it works then.

  5. trinzia
    Member
    Posted 2 years ago #

    You're right, S2Member has a setting for this too, so I'd better look there first since it seems to be the active setting.
    Thanks.

  6. grayayer
    Member
    Posted 1 year ago #

    I've also found the plugin bbPress to cause this type of problem.

  7. fitninja
    Member
    Posted 1 year ago #

    The redirection isn't working for me either.

    I've also disabled the dashboard and I use bbpress which is an important part of my site, so not using bbpress is not an option.

    Hopefully the developer will figure out a way to get this plugin to work properly with those others because I like the functionality it promises.

  8. iisg
    Member
    Posted 1 year ago #

    Hello All,

    I'm having the same problem, after logging in it won't redirect to Referer, nor does it redirect to where I tell it with the option after that.

    Any suggestions?

    Thanks

  9. Jeff Farthing
    Member
    Plugin Author

    Posted 1 year ago #

    I suggest you all disable all other plugins and see if it works then.

    Report your findings here.

  10. ragamffn
    Member
    Posted 1 year ago #

    Ya bbpress prevents TML redirect from working here as well.

    Deactivate bbpress, TML redirects work fine. Activate bbpress, TML no longer redirects - it always directs user to home page, regardless of role or redirect settings.

  11. Jeff Farthing
    Member
    Plugin Author

    Posted 1 year ago #

    I'll look into testing with bbPress when I get a chance.

  12. andybarnes102
    Member
    Posted 1 year ago #

    Does any one know of a workaround, other than not using bbPress(!)? Really diluting the usability of the site when users have to navigate back to where they were before logging in.

  13. the3seashells
    Member
    Posted 1 year ago #

    If you look in the bbpress directory, and navigate to includes > core > filters.php, you may comment out lines 47 and 48 (filtering login_redirect and logout_url).

    Because this edits a core bbpress file, it will need to be repeated if you update bbpress.

  14. ragamffn
    Member
    Posted 1 year ago #

    If you look in the bbpress directory, and navigate to includes > core > filters.php, you may comment out lines 47 and 48 (filtering login_redirect and logout_url).

    Because this edits a core bbpress file, it will need to be repeated if you update bbpress.

    I've confirmed this works with TML 6.2.3 on WP 3.5 and BBPress 2.2.3. Thanks the3seashells!

    R

  15. Anointed
    Member
    Posted 1 year ago #

    Is there a 'real' fix for this?

    I can't imagine that JJ is doing something that wrong with bbPress. and having to manually update bbPress on each update is a non-starter as I use the nightly svn on a cron job.

  16. Jeff Farthing
    Member
    Plugin Author

    Posted 1 year ago #

    Just because bbPress has it's own redirection settings, as does TML, doesn't mean either one of them is doing anything wrong.

    Try adding this to wp-content/plugins/theme-my-login-custom.php:

    function tml_init() {
    	remove_filter( 'login_redirect', 'bbp_redirect_login', 2,  3 );
    	remove_filter( 'logout_url',     'bbp_logout_url',     2,  2 );
    }
    add_action( 'bbp_init', 'tml_init' );
  17. aaclayton
    Member
    Posted 1 year ago #

    Works brilliantly Jeff, thanks so very much!

  18. qim
    Member
    Posted 1 year ago #

    Dear Jeff

    I hope you are still around
    Itoo am unable to get redirection to work.

    You wrote taht the code above should be placed in wp-content/plugins/theme-my-login-custom.php: but I don't seem to have that file. the nearest isi n wp-content/plugins/theme-my-login/modules/custom-redirecton/custom-redirection.php

    I am using WP 3.5.1 and theme Adventure-Journal

    Any help appreciated

    qim

  19. Jeff Farthing
    Member
    Plugin Author

    Posted 1 year ago #

    You have to create the file.

  20. qim
    Member
    Posted 1 year ago #

    Hi and thanks

    I'm afraid it still does not work.

    I created a file named theme-my-login-custom.php and placed it in wp-content/plugins/ wirth the code in the box above, but visitors(subscribers)still do not get redirected to the third-party url that is specified. They come back to the main page with a Not Found.

    I wonder if I should have put the file in the child folder.

    qim

  21. leejosepho
    Member
    Posted 1 year ago #

    edit

  22. Jeff Farthing
    Member
    Plugin Author

    Posted 1 year ago #

    If the URL is not in the same domain, it won't work.

  23. sujit.tripathi@gmail.com
    Member
    Posted 1 year ago #

    Hi.

    The Redirection module is not working how I thought it would. it return the blank page on login ,register and also at the forget password event..

    i have deactive all plugin but same problem.....................................................

  24. sujit.tripathi@gmail.com
    Member
    Posted 1 year ago #

    Hi.

    The Redirection module is not working how I thought it would. it return the blank page on login ,register and also at the forget password event..

    i have deactive all plugin but same problem.....................................................

  25. jtost
    Member
    Posted 1 year ago #

    Hi Jeff,

    I have the same problem without bbPress. The steps I do are these:

    1. I type in the browser a private page URL.
    2. I get the WordPress login page
    3. When I log-in, the site redirects to the profile page, instead to the private page that I want to visit.

    This is happening with a Subscriber user role, but also with the others. I thought it was because I was using WP Members to controle private content, but I have deactivated the plugin and the problem persists.

    Thanks in advance for your help!

  26. jtost
    Member
    Posted 1 year ago #

    Just add that "Referer" is working well on log-out.

  27. A. J.
    Member
    Posted 1 year ago #

    Anyone know of a My theme login widget that will redirect to the correct private share page based on the username/password combo? I'm looking for something that's an actual login/logout widget ?
    please

Topic Closed

This topic has been closed to new replies.

About this Plugin

About this Topic