The Arcive of vBulletin Modifications Site. |
|
|
#1
|
|||
|
|||
|
Hi all,
I have a fairly simple question, I have tried numerous ways of doing this with out much luck Writing a basic modification for my site and it uses vbulletin usergroup permissions to access it. I wanted to do something like this but it does not work PHP Code:
I am going to make a backend that uses SQL in the future so the variable will end up being a call to the database... |
|
#3
|
|||
|
|||
|
Quote:
Cheers Mick |
|
#4
|
|||
|
|||
|
If this doesn't work:
Code:
$webspace_canuse_global = '6,7,18';
if (!is_member_of($vbulletin->userinfo, $webspace_canuse_global)) {
print_no_permission();
}else{
// do the script
Code:
$webspace_canuse_global = '6,7,18';
if (!is_member_of($vbulletin->userinfo, explode(',', $webspace_canuse_global))) {
print_no_permission();
}else{
// do the script
Oh, and keep the numbers seperated by commas only. Not commas and spaces. |
|
#5
|
|||
|
|||
|
explode worked (thank you), I had a feeling it might need explode, just thought there would be a more kinder way to do it.
Regards Mick |
| Благодарность от: | ||
| Black Snow | ||
![]() |
|
|