Hi to all, sorry in advance for my bad english, i’m new to geodirectory but i found your work really great!
I’m using your plugin with supreme theme to listing coaches instead of shops, for now all is almost working, i’m going to buy multilocator and andvanced searh addons to fill my needs.
At the moment i’m using Stiofan code below to redirect users after login/registration:
// redirect after login/reg
add_filter('login_redirect','my_login_reg_redirect',10,3);
function my_login_reg_redirect($redirect_to, $requested_redirect_to, $user){
//only redirect if not being redirected somewhere important like back to add listing page.
if( trailingslashit($redirect_to) == trailingslashit(home_url())){
$redirect_to = home_url('/add-listing/');
}
return $redirect_to;
}
All works great but my needs is to redirect users only after registration, not after login.
So i found this code also in this community:
add_filter('geodir_login_url','_my_geodir_login_url',10,3);
function _my_geodir_login_url($login_url,$args,$gd_page_id){
if(isset($args['signup'])){
//change the url to whatever you want.
$login_url = '/add-listing/';
}
return $login_url;
}
But this not working at all redirecting users on last page visited before registration and on rapid link register on the header box i got a blank page with:
[an error occurred while processing this directive]
This is my testing website
Any help will be appreciated, thanks in advance.
Valdo