if equal steamid
How to read two or more steamids with if equal?
PHP Code:
|
Re: if equal steamid
Use a const and loop trough all the SteamIDs in it. I think this is the best way to read two or more steamids at once.
EDIT: Moved that new variable for name outside the loop. PHP Code:
|
Re: if equal steamid
Quote:
|
Re: if equal steamid
My bad, didn't know that one. Will update asap when I get home.
|
Re: if equal steamid
What's wrong in this menu?
If I'm ADMIN (ADMIN_BAN) the menu for ADMIN is displayed, If I'm VIP (ADMIN_LEVEL_A) the menu for VIP is displayed, If I'm USER (flag z no admin) the menu for users is displayed, Well It's all ok, but if I'm the SteamID, the menu does not open, why? PHP Code:
PHP Code:
|
Re: if equal steamid
Code:
Code:
|
Re: if equal steamid
Quote:
|
Re: if equal steamid
Does for me. (Apart from the missing handler, so it's actually not opened but at least I get an error.)
I can see that's not your actual code since it doesn't even compile. Share the real code or figure it out yourself. |
Re: if equal steamid
Handler can be null. The menu must open if the code is ok
PHP Code:
|
Re: if equal steamid
If the admin's SteamID is in the list, they will be shown two menus (the SteamID specific one and then the User one overwrites it).
Also, to improve efficiency, I would consider using a Trie for the SteamIDs. You will no longer need to use a loop to determine if they are in the list, it would change your loop to an if statement. This would make it easier solve the problem above because you could simply to else ifs for everything else. |
All times are GMT -4. The time now is 17:15. |
Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.