-
Hey Ahmed, i’m want to direct users to the login page after they have Activated their Email. Is this possible?
I also wanted to add a query string login/?redirect_to=http://example.com/example so that it would take them to that page after they logged in.Would really appreciate your help on this matter. Thanks mate 🙂
Hi there! 🙂
What currently happens when they click the email activation link? Where do they go?
Thanks!
This is what happens after email activation:
$this->activate( $_GET[‘user_id’] );
wp_redirect( add_query_arg(‘accountconfirmed’, ‘true’, $this->permalink() ) );
exit;So they are taken already to profile, and a notice saying their account is confirmed, they can login. Why it is not doing the same for you?
They click the link and are taken to the homepage with the query string attached.
It doesn’t take them to a login page.Is there a custom code i could add in that would redirect them to a login page with a query string on the end that would redirect them after login?
Try:
wp_redirect( add_query_arg(‘accountconfirmed’, ‘true’, $this->permalink(0, ‘login’) ) );
Should redirect them to LOGIN page. Are you sure you have setup userpro pages correctly?
I don’t have my pages setup correctly. I have setup the login page to be /login rather than /profile/login
Not sure if it’s still possible to do?
Sorry, i just checked. The login and Signup pages are still registering in the Check / Rebuild Profile Pages options page.
So they are setup correctly and linked in there.
The members directory, logout and edit profile aren’t however, i’ve privatised those pages
Please change the wp_redirect location to point to your login page 🙂
You must be logged in to reply to this topic.