SMF Support > SMF 2.0.x Support
Custom LOGOUT probem
MoneyMan87:
I have connect the smf with my custom script on my site when i login all is perfect but when i press from my script logout write me this error:
An Error Has Occurred!
Session verification failed. Please try logging out and back in again, and then try again.
Know someone how can i fix it please?
This is my site: http://l2votezone.com
Thanks in advance!
Arantor:
So, this page on your site, did you include SSI.php first? Any other custom code?
URL to the forum, URL to the custom page?
(Details are important)
MoneyMan87:
yes i have it
--- Code: --- require("forum/SSI.php");
--- End code ---
the custom code for login logout is this:
--- Code: ---<?
if ($context['user']['is_guest'])
{
echo '
<form action="forum/', '?action=login2" method="post" accept-charset="', $context['character_set'], '">
<table border="0" cellspacing="1" cellpadding="0" class="ssi_table">
<tr><td width="10"><img class="img" src="images/user.png" width="17" height="19" alt="" /></td><td><input type="text" id="userinput" name="user"/></td></tr>
<tr><td width="10"><img class="img" src="images/pass.png" width="17" height="19" alt="" /></td><td><input type="password" name="passwrd" id="passinput" /></td></tr>
</table>
<input type="submit" value="" id="login"/>
<a href="forum/register/" id="register"><img src="images/register.png" alt="" border="0" /></a>
<div id="ltext">
<a href="forum/request/password/">Forget Password?</a>
<input type="checkbox" id="input" name="save_pass" value="1" /><span>Remember me</span></div>
</form>';
}
else
{
echo "<div class=\"usermenu\">";
echo "<a href=\"myhome\"><img src=\"images/button1.png\" width=\"90\" height=\"23\" alt=\"\" /></a><br />";
echo "<a href=\"forum/pun_pm/inbox/\"><img src=\"images/button2.png\" width=\"90\" height=\"23\" alt=\"\" /></a><br />";
echo "<a href=\"forum/". '?action=logout;' . $context['session_var'] . '=' . $context['session_id'] . "\"><img src=\"images/button3.png\" width=\"90\" height=\"23\" alt=\"\" /></a>";
echo "</div><div id=\"ltext\" style=\"padding-top: 5px;\">";
echo "Logged in as: " .$user_info['username']. "";
if ($context['user']['is_admin'])
{
echo " | <a href=\"admin\">Admin Panel</a>";
}
echo "</div>";
}
?>
--- End code ---
forum url: http://l2votezone.com/forum
Arantor:
Admin > Configuration > Server Settings > Cookies and Sessions > Enable subdomain independent cookies
Log out, log back in and it should work as expected.
MoneyMan87:
Again I have the problem :(
Navigation
[0] Message Index
[#] Next page
Go to full version