The Arcive of Official vBulletin Modifications Site.It is not a VB3 engine, just a parsed copy! |
|
#1
|
|||
|
|||
Requring members to input a password EACH session to view a forum
Hi guys
I was really hoping someone could help me, I have a forum which is private and deals with a very personal topic which members do not want their husbands or wives finding out about (depression etc) At the moment it seems like if I set the password for Forum A once the user inputs the password and closes the browser and reopens it, it does not ask for the password to be entered in. I would prefer it ASK to re enter the password each time the browser is reopened heck I wouldn't even mind having to enter it every time someone wanted to view the forum. Secondly a way to prevent browsers from saving the password? Tahnks so much! |
#2
|
|||
|
|||
It looks like forum passwords are saved in cookies with long expiration times, and the cookie name is COOKIE_PREFIX . 'forumpwd'. So you might be able to make a plugin that deletes that value from $_COOKIES early on, like in global_start or something. But I think that might result in a user having to enter a password every time they click on anything in a password-protected forum, which might be too much.
I think if you had the cookie saved with an expiration time of 0 then it would only last until the browser was closed, which sounds more like what you want. In forumdisplay.php around line 140 there's this code: Code:
// set a temp cookie for guests if (!$vbulletin->userinfo['userid']) { set_bbarray_cookie('forumpwd', $foruminfo['forumid'], md5($vbulletin->userinfo['userid'] . $vbulletin->GPC['newforumpwd'])); } else { set_bbarray_cookie('forumpwd', $foruminfo['forumid'], md5($vbulletin->userinfo['userid'] . $vbulletin->GPC['newforumpwd']), 1); } BTW, I haven't actually tried any of this. |
#3
|
|||
|
|||
Tried changing the 1 to 0 nothing changed.
I had a look at the Cookie bbforumpwd is what set in the Cookie Thanks so much for your reply kh99! |
#4
|
|||
|
|||
On second thought, I think my first idea about deleting the cookie might result in not being able to use the forum at all.
Changing the 1 to 0 I thought should have made it so that if you closed the browser and opened a new one, you had to enter the password again. Did you try that? Maybe I'm wrong... But I didn't really understand your last post - did you solve your problem? |
#5
|
||||
|
||||
When you change it from 1 to 0, you will then need to clear your own cookies initially to see if it works.
|
#6
|
|||
|
|||
Quote:
I just forgot to clear ALL cookies :P One final question, how can I make sure the password field doesn't get prompted to be saved on entry by the browsers? Just like for entering your bank password it never promts for the password to be saved. Again thanks so much! |
#7
|
||||
|
||||
I don't know that you can do that. There are so many addons out there to save information you input into textareas - not just username/password fields.
|
#8
|
|||
|
|||
I know vbulletin.com has the members area so that the password can't be saved (at least on my browser it won't LOL)...the only thing I can find on it is to add autocomplete="off" to the input code like so:
<input type="password" name="password" id="password" autocomplete="off" /> I don't know if this is the only part that disables the password being saved, but worth a try Hope it helps anyway lol Lissa |
#9
|
|||
|
|||
Interesting mate! Which template do I find that string I did a search via Search in Templates for keyword 'password' all of it doesn't seem relevant, thanks!
Lynne: I noticed that as the Admin/Super Admin I am not forced to enter the password, ever. Is there anyway to make it so that Admins, Mods and Super admins are forced to enter the password each session? Thanks so much! |
#10
|
||||
|
||||
You would need to edit the actual php code to make it so everyone, including admins/mods, would have to enter a password. Check the function verify_forum_password and you should find the code.
|
|
|
X vBulletin 3.8.12 by vBS Debug Information | |
---|---|
|
|
More Information | |
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|