Page 1 of 1

Logout link not working

PostPosted: September 5th, 2011, 7:41 pm
by antseo
I'm using a logout link but it's not working. The code I have is:

<a href="<?php echo wp_logout_url( home_url() ); ?>" title="Logout">Logout</a>

Not sure if this is causing the issue but the wordpress url (in the General section in admin area) is different than the site url.

Would s2member cause that issue? the logout should be redirecting to the wp-login.php page, right?

Re: Logout link not working

PostPosted: September 6th, 2011, 3:30 pm
by antseo
Any idea on this?

Re: Logout link not working

PostPosted: September 7th, 2011, 2:35 am
by Cristián Lávaque
When you say "it's not working" what do you mean? What does home_url() output? Does it match with the site or WordPress URL setting you mentioned from WP Admin -> Settings -> General?

Could this be related to the subdomain change you mentioned in another thread? viewtopic.php?f=4&t=14873&p=34060#p34060

Re: Logout link not working

PostPosted: September 7th, 2011, 9:38 am
by antseo
yes, I believe it was related. I made the switch which fixed that issue. Thanks Cristian!

Re: Logout link not working

PostPosted: September 8th, 2011, 12:51 am
by Cristián Lávaque
That's great! :)