Error Logging
Error Logging
When debugging is disabled, there can be situations where PHP errors can cause a white screen, or there can be errors that are completely invisible to the user but result in incorrect execution of a given page.
To find these errors, it is recommended to enable logging in ExpressionEngine.
To enable error logging, you need to do the following:
- Create a
logs
folder inside yoursystem/user
folder and make sure it’s writable - Open the
config.php
file and add the following config overrides:log_threshold
(required)log_date_format
(optional)
Example:
$config['log_date_format'] = 'Y-m-d H:i:s';
$config['log_threshold'] = '1';
After adding the two config file items above, PHP errors, warnings, etc. will be logged to a file with the corresponding date inside the system/user/logs
folder.