- Sat Feb 15, 2020 1:01 pm
#827559
If your plugin uses this (e.g. to insert data into a dropdown list) and you have upgraded to PHP 7.1, these nuisance errors now show on the screen even if PHP error reporting config has been set not to show them.
I have used this workaround to help silence the errors. Insert at the beginning of your plugin script:
error_reporting(E_ALL & ~E_NOTICE & ~E_WARNING);
Normal error reporting should resume outside scope of the script.
I have used this workaround to help silence the errors. Insert at the beginning of your plugin script:
error_reporting(E_ALL & ~E_NOTICE & ~E_WARNING);
Normal error reporting should resume outside scope of the script.