1and1 Help Centre Categories

print article

Activate PHP Error Logs

For 1&1 Linux packages

Use the following codes to enable error logging. Copy and paste the code below into a php.ini text file. This php.ini file should be saved in the webspace folder containing that website files that should be monitored for logging.

Please note:
Replace /homepages/27/d382162338/htdocs/ in the code below with the full path to the root of your webspace.
error_reporting = E_ALL | E_STRICT
log_errors = On
display_errors = Off
error_log = /homepages/27/d382162338/htdocs/php-errors.log
Code Meaning
error_reporting = E_ALL | E_STRICT This line specifies which errors should be recorded. E_ALL indicates that all errors and warnings should be recorded. E_STRICT suggest changes in coding and ensures compatibility with future PHP-versions.
log_errors = On Errors in the log file are recorded.
display_errors = Off Browser errors will not to be displayed.
error_log = /home/d123456789/private/php-errors.log Errors will be recorded into the respective folder in your private directory.
For additional information, you may want to reference: