View Full Version : auto logout when close browser???
chipheodeptrai
08-03-2002, 09:13 AM
Hi
Im looking for a hack about "auto logout when close browser???"
thanks for your ;) help
Logician
08-04-2002, 04:26 PM
Technically not possible.. Closing the browser occurs in user side and a site can not detect (and act accordingly) browser closing..
You can use another trick though: Edit the relevant templates and delete "remember me" setting from settings (make it hidden and set it to no) so your users can't choose this option and need to relogin everytime they come to your site.. ;)
chipheodeptrai
08-04-2002, 04:35 PM
TIA
but where is relevant templates ?
Logician
08-04-2002, 04:54 PM
registeradult
registercoppa
modifyoptions
Delete part:
<td bgcolor="{firstaltcolor}"><normalfont><b>Automatically login when you return to the site? (uses cookies)</b></normalfont></td>
<td bgcolor="{firstaltcolor}"><normalfont>
<input type="radio" name="cookieuser" $cookieuserchecked value="yes"> yes
<input type="radio" name="cookieuser" $cookieusernotchecked value="no"> no
</normalfont></td>
And add
<input type="hidden" name="cookieuser" value="no">
after
<form action="member.php" method="post"><input type="hidden" name="s" value="$session[dbsessionhash]">
(This line can be different in register templates, find similiar one add the line after it)
chipheodeptrai
08-04-2002, 05:12 PM
i fixed but it not working :(
Logician
08-04-2002, 06:37 PM
what do you mean by "not working"? If you applied it correctly a new member or an existing member who updates his options will be forced to login everytime they come to your site. Of course this change does not cover existing members who already set this option to YES before you change the templates. You need to run a SQL query to update existing users' options in your database to apply this change to them..
chipheodeptrai
08-06-2002, 01:08 PM
OKIE
thanks so much...all fine now...
great man....lol
regards
vBulletin® v3.8.12 by vBS, Copyright ©2000-2024, vBulletin Solutions Inc.