PDA

View Full Version : Custom user setting saved in cookie?


DISLEX
07-16-2008, 03:00 PM
So I added a new userfield in a user's options page that allows them to toggle worksafe mode. Now I want to be able to store that setting in a cookie, so if they turn it on at work, it's always on at work, but when they come home, its off. How can I manage the setting like this? I don't mind getting down into the PHP of vB if that's necessary.

Opserty
07-16-2008, 03:05 PM
Look for vbsetcookie() in vBulletin 3.7 Code Documentation (http://members.vbulletin.com/api/)

Then just read the cookie as you would any normal one.

DISLEX
07-17-2008, 02:03 AM
thanks