Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
我在 config.php 中有这段代码
//Username of the Administrator $admin='1';
我的网站采用具有“1”ID 的用户,但我想在此变量中设置多个管理员。同样,我尝试了一些代码,例如
$admin=arry('1', '2')
您需要更改检查 $admin 的位置:
if ($userId == $admin) {}
至
if (in_array($admin, $userId)) {}