![]() |
Did you try the edit at the end of step 4 in troubleshooting?
|
I'm trying to restrict access to pages based on Usergroups, but I can't figure out what I shoud do with the code you provided. I have tried it in different locations on the page, but whether I'm logged in or not it always shows me the page. Any help? (The user login works perfectly for me, btw.)
|
Quote:
|
Right now I have it at the top of the page, and I'd like to restrict this page's access to those who attend here only. I've also tried replacing the 'Have stuff for here' with the content of the page, and that didn't work either. I realize I must be missing the obvious, but I'm just stumped at this point. Thanks for any help. :)
PHP Code:
|
Ok, I see whats gone wrong.
The "have stuff here" line is where you put your page contents. For example; PHP Code:
I may have missed escaping a " somewhere (I have a habit of doing that) but you should get the idea of how it works. |
That works great, but is there a way to set it for access from multiple usergroups? ie, Members are usergroup 9 and Admins are usergroup 6. I've tried it as
PHP Code:
PHP Code:
PHP Code:
|
Try
something like Code:
if ($vbulletin->userinfo['usergroupid'] == '9' |
Quote:
|
Quote:
Others may find it usefull as well. |
Is there a way of making it remember a user without the 'Remember me?' checkbox?
Thanks. |
All times are GMT. The time now is 08:22 AM. |
Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2025, vBulletin Solutions Inc.
X vBulletin 3.8.12 by vBS Debug Information | |
---|---|
|
|
![]() |
|
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|