Is it safe to trust $_SERVER['REMOTE_ADDR']
? Can it be substituted by changing the header of request or something like that?
Is it safe to write something like that?
if ($_SERVER['REMOTE_ADDR'] == '222.222.222.222') { // my ip address
$grant_all_admin_rights = true;
}