Login/Registration redirect

I am trying to add a login/registration on my forum:

Since the forum uses bbpress, it has its own login at the bottom of the forum, but no REGISTER button.

I initially tried the s2M login (in the light blue box), but the Signup now, redirects to the Membership Option page, instead of the
https://lettersfromthenorthpole.com/wp-login.php?action=register
as it says in the documentation

So, I made a separate one (currently in the green box). So I managed to direct it to the WP registration page. That works.

Next step would be to have a logout button. That is another challenge. Although the Login on the s2M form works, if I copy the link into my green box, it does not log the user out.

So, I am a bit stuck.
The s2M login/register works except for the REGISTER that redirects to the wrong page.
The custom box I did works for the REGISTER but not for the LOGOUT.

What am I missing?

I saw the code you sent me privately. Could you please try the logout link without the nonce?

https://lettersfromthenorthpole.com/wp-login.php?action=logout&redirect_to=/

Trying that code, Cristian, still won’t let the user LOG OUT.
I tried the URL on its own in the browser and it DOES log out, so the link is ok. It just won’t work inside the code.
I tried removing the conditional. Using Elementor, I tried putting that code in a shortcode widget, in a html widget, in a text widget, but i get the same result: it won’t log the user out.

BINGO!!! found a solution.
After searching further, I found yet another Elementor widget called Custom HTML (different than a HTML block or a TEXT(HTML) widget). And this one works fine now. It lets me register AND log out.

Thanks for at least correcting my syntax in the first place!
(now, you can come and order letters from Santa for your kids, nephews, etc. :smiley:)

1 Like

Well done! I’m very glad you sorted it out. :smiley:

I still don’t know why the LOGOUT link didn’t work, while the REGISTER link did, in that same block. But at least, it works now!

1 Like