If I understand right, you want to remove the “Create an account” checkbox and instead of this you want to add a form where you have a textfield that says: “To create an account and manage your previous ads, click here” ?
Hi, you can change the registration URL by adding following code to your theme functions.php file
add_filter('login_url', 'my_login_url');
function my_login_url( $url ) {
if( is_admin() ) {
return $url;
}
return "https://example.com/custom/login/url";
}
Of course replace the https://example.com/custom/login/url with actual URL you want to redirect user to.
Hi Greg, tanckom,
Thanks for both your replies. I have managed a solution by restricting access to signed in users only to my “Submit Advert” and “Manage Adverts”. I did this using a “Page Restrict” plugin which I have been using for some time.
However…..all I need to do now is to remove the:
“Create an account for me so i can manage all my ads from one place (password will be emailed to you) or Sign In”
line from the “Add” form.
How do I do this?
Again, many thanks in advance.
Chris
Hi Guys,
Panic over! I have managed to work it out and edit the functions.php file.
Thanks again,
Chris
Still having problems!
What I want to do now, is direct unregistered users to the registration page:
http://liveinfo.lagosnavigators.net/httpdocs/contact-us-2/register/
when they see this page and hit the “register” link:
http://liveinfo.lagosnavigators.net/httpdocs/adverts-2/manage/
Any advice please?
Many thanks.
Chris
Similarly as with login_url, you can use registration_url to change this link
add_filter('register_url', 'my_register_url');
function my_login_url( $url ) {
if( is_admin() ) {
return $url;
}
return "https://example.com/custom/register/url";
}
Thanks Greg,
Unfortunately, I cannot get this code to work.
You can try the “register” link here:
http://liveinfo.lagosnavigators.net/httpdocs/adverts-2/manage/
Any ideas please?
Many thanks,
Chris
Sorry the code should be
add_filter('register_url', 'my_register_url');
function my_register_url( $url ) {
if( is_admin() ) {
return $url;
}
return "https://example.com/custom/register/url";
}
Thanks Greg!
Working great now.
Many thanks for your help. Great Plugin!
Chris
Sure, no problem :).
BTW. If you are finding the plugin useful i would be thankful if you could write a short one or two sentence review here https://ww.wp.xz.cn/support/view/plugin-reviews/wpadverts