Limited Support
Our team is currently on holiday, so support will be limited during this period. Response times may be slower than usual, and some inquiries may be delayed.
We appreciate your patience and understanding, and we’ll resume our usual support by the end of August.
Hi all,
I've had to hard code a custom URL into my forum navigation.
I've actually edited the forum .php template and not used the menu function as my website uses a custom login/signup process and a popup box.
As such, I've entered the HTML code into the php file in the back end so it has a custom Login/Register URL popup box on the nav bar.
However, I want this URL to vanish when a user is logged in.
Does anyone know what code I can wrap around this link to stop it showing when a user is logged in?
Any help/advice would be greatly appreciated.
TIA
Hi @uforeport,
I'd suggest you remove the customization you've done and use the solution explained in this support topic:
Pay attention to this part.
If you remove the #wpf-msg-box selector from the code above, it'll replace all login links (wpForo).
Another option if you want to use your codes you can add extra codes using is_user_logged_in() Wordpress function to hide the menu item for logged-in users.
More info here:
https://developer.wordpress.org/reference/functions/is_user_logged_in/
Thank you very much