mirror of
https://github.com/Fluffy-Bean/image-gallery.git
synced 2025-01-07 15:26:00 +00:00
19 lines
290 B
PHP
19 lines
290 B
PHP
|
<?php
|
||
|
/*
|
||
|
Check if user is admin
|
||
|
|
||
|
Returns True if user is privilaged
|
||
|
Returns False if user is NOT privilaged
|
||
|
*/
|
||
|
function is_admin($id) {
|
||
|
if (isset($id) || !empty($id)) {
|
||
|
if ($id == 1) {
|
||
|
return True;
|
||
|
} else {
|
||
|
return False;
|
||
|
}
|
||
|
} else {
|
||
|
return False;
|
||
|
}
|
||
|
}
|