Arrow

Redirect to post | Peter's Login Redirect | Forum

Back to the login redirect plugin page

Please consider registering
guest

Log In

Lost password?
Advanced Search

— Forum Scope —

  

— Match —

   

— Forum Options —

   

Minimum search word length is 4 characters - maximum search word length is 84 characters

Topic RSS
Redirect to post
August 9, 2010
4:02 am
Jony
Guest

hi first of all thanks for such a great plugin , my problem is that when i redirect any specific user such as 'Editor' it redirects perfectly but if any user having role of 'editor' need to comment on any post after login redirect back to that post it is redirected to the page i redirected it previously,i need to redirect specific role user to specific page when he log in like "wp-login" not when he needs to comment on any post ,is their any way to solve this problem using this plugin for e.g when any user having role of 'editor' login it is redirected to http://www.example.com/?p=7 but when that user login to comment on any post i need to redirect back to that post instead of http://www.example.com/?p=7 ,thanks a ton

August 9, 2010
10:07 pm
Peter
Admin
Forum Posts: 841
Offline

In the function "redirect_wrapper" in the plugin, you could add this code after the first "if" statement:

if( admin_url() != $redirect_to )
{
return $redirect_to;
}