NooTheme Premium WordPress Theme › Forums › JobMonster › Redirect Issue
- This topic has 11 replies, 2 voices, and was last updated 4 years, 4 months ago by contactmaid.
-
AuthorPosts
-
4 years, 4 months ago #1174411
hey i was using peter login redirect to redirect employers and candidates after login but yesterday we updated our theme and after that , this function not working anymore , i was redirecting candidates to job archive and employers to resume archive , thanks
4 years, 4 months ago #1174794This reply has been marked as private.4 years, 4 months ago #1175179This reply has been marked as private.4 years, 4 months ago #1175202I see it still working, please check your site again.
best regards.
4 years, 4 months ago #1175213hey dangdv how you are checking its keep redirecting me to the member page for both employer and candidate after login...
4 years, 4 months ago #1175221That problem because you not add custom code for Employer login, you only add custom code for Employer register,
To change URL after employer login, please add custom code in file functions.php of your theme.
add_filter( 'login_redirect', function($redirecturl, $user_signon){ if(Noo_Member::is_employer($user_signon->ID)){ $redirecturl = get_post_type_archive_link('noo_resume'); } return $redirecturl; },10,2);
best regards,
4 years, 4 months ago #1175224thanks bro and please tell me the code for candidate as well to redirect it to job archive job
4 years, 4 months ago #1175226Yes, if you want do it, please change custom code to
add_filter( 'login_redirect', function($redirecturl, $user_signon){ if(Noo_Member::is_employer($user_signon->ID)){ $redirecturl = get_post_type_archive_link('noo_resume'); }elseif (Noo_Member::is_candidate($user_signon->ID)){ $redirecturl = get_post_type_archive_link('noo_job'); } return $redirecturl; },10,2);
Best regards.
4 years, 4 months ago #1175229Thanks for support but please can you check for me by login
user: CANTEST
pass:password123
because its not working for both candidate and employers
4 years, 4 months ago #1175234I think that problem because conflict with User redirect plugin on your site, you can deactiva that plugin to check again.
4 years, 4 months ago #1175236i already deactivated my redirect plugin but still i have the same problem. and can you mark as private my above reply
4 years, 4 months ago #1175242code is working perfectly now that you gave me , there was a problem with my plugin in please mark as resolved.
-
AuthorPosts
You must be logged in and have valid license to reply to this topic.