When E_NOTICE is set to on, PHP will report undefined index for arrays. I want to suppress this error for $_GET only. Is there any way to do that other than prepend
The proper solution is to use something like isset or array_key_exists first, thus making sure your code successfully handles things when the array index is outright missing, as opposed to '' or zero: