Shows an example configuration of a custom error handler (TYPO3 CMS)
Adds a custom error handler which redirect to a predefined page based on given error and/or status code.
This example uses no 3rd party libraries.
Add the following snippet to your site configuration (e.g. typo3conf/sites/<your_site>/config.yaml
)
errorHandling:
- errorCode: 404
errorHandler: PHP
errorPhpClassFQCN: Passionweb\CustomErrorHandler\Error\CustomErrorHandler
- errorCode: 403
errorHandler: PHP
errorPhpClassFQCN: Passionweb\CustomErrorHandler\Error\CustomErrorHandler
There are no extension settings available.
If something does not work as expected take a look at the log file.
Every problem is logged to the TYPO3 log (normally found in var/log/typo3_*.log
)
I'm grateful for any feedback! Be it suggestions for improvement, requests or just a (constructive) feedback on how good or crappy this snippet/repo is.
Feel free to send me your feedback to service@passionweb.de or contact me on Slack