Richie
Not New Member
^ Yes, That's My Fugly Face!
Posts: 35
Richie said 2 great things
|
Post by Richie on Apr 6, 2010 15:15:53 GMT -8
Code Title: Auto-select "forever" in login dropdown Location: Global FootersDescription: This will make the "Stay logged in for" part of the login form be "forever" by default while also removing the dropdown (OPTIONAL), which will force all members to login as "forever" (which will help prevent any login issues). Preview: ClickCode: <script type="text/javascript"> /* auto-select "forever" in login dropdown */
var remlog=1; // Set to 0 To Show The Drop Down
if(document.loginform){ document.loginform.minutes.options.selectedIndex="9"; if(remlog) document.loginform.minutes.parentNode.parentNode.style.display='none'; } </script> Additional Info: to keep the dropdown, just remove the red part.
|
|
|
Post by Wormopolis on May 20, 2011 3:21:32 GMT -8
this code is no longer relevant since the drop down was replaced.
|
|
wildgoosespeeder
Code Helper
Tiers are for strangers!
Posts: 530
wildgoosespeeder said 161 great things
|
Post by wildgoosespeeder on May 20, 2011 12:22:31 GMT -8
All it really takes is: <script language="javascript"> /* Auto-select "Forever" in Login Dropdown */ /* Global Footer - Open Source */ if(document.loginform) { document.loginform.minutes.checked = true; } </script>
|
|
|
Post by Wormopolis on May 20, 2011 14:15:59 GMT -8
and even then... Its a slight risk having it on there if someone (somehow) didnt notice that the box was checkmarked when they submitted. public computers open up security holes to accounts.
at least this version doesnt set the checkmark and hide the option to change it back.
|
|
wildgoosespeeder
Code Helper
Tiers are for strangers!
Posts: 530
wildgoosespeeder said 161 great things
|
Post by wildgoosespeeder on May 21, 2011 14:56:15 GMT -8
OK, random thought there... So what you are saying is the version I posted is better than Richie's?
|
|
|
Post by Wormopolis on May 21, 2011 19:19:38 GMT -8
Its better because it still works, but I would suggest anyone to not even use it and leave that checkbox as an opt-in choice instead of automatic one.
|
|