1

I don't want to turn on ini_set() for security reasons. So per CSF's recommendation, I did add it to be unset.

However, a drupal site gives this error, but I want to remove the error (or hide it) without actually enabling ini_set().

DavidPostill
  • 162,382
superuser
  • 3,574
  • 8
  • 29
  • 47

1 Answers1

1

You can disable showing of PHP warnings, either in server main php.ini or custom php.ini on the account.

edit /usr/local/lib/php.ini, and change error_reporting value to following, to not show notices and warnings.

error_reporting = E_ALL & ~E_NOTICE & ~E_WARNING

if you want do it by custom php.ini on the account, copy the main php.ini to user folder and edit that file.

cp /usr/local/lib/php.ini /home/$user/public_html/php.ini 

and then edit that file, and change error_reporting

ralz
  • 2,566