Error handling¶
Error handling can be configured on site level and is automatically dependent on the current site and language.
The configuration consists of two parts:
- The HTTP Error Status Code that should be handled
- The Error Handler Configuration
You can define one error handler per HTTP error code and add a generic one that serves all error pages.
Attention
Exceptions must be handled via Error and exception handling since they occur on a much lower level. These are currently not covered by site error handling.

Add custom error handling.
Properties¶
errorCode¶
- Datatype
- int
- Description
- The HTTP (Error) Status Code to handle. The predefined list contains the most common errors,
a free definition of other error codes is also possible. Special value
0
will take care of all errors. - Example
404
errorHandler¶
- Datatype
- string / enum
- Description
- Define how to handle these errors. May be
Fluid
for rendering a Fluid template,Page
for fetching content from a page orPHP
for a custom implementation. - Example
Fluid
errorFluidTemplate¶
- Datatype
- string
- Description
Only if errorHandler == `fluid`: Path to fluid template file. Path may be
- absolute
- relative to site root
- starting with
EXT:
for files from an extension
- Example
EXT:sitepackage/Resources/Private/Templates/Error.html
errorFluidTemplatesRootPath¶
- Datatype
- string [optional]
- Description
- Only if errorHandler == `Fluid`: Paths to Fluid Templates, Partials and Layouts in case more flexibility is needed.
- Example
EXT:sitepackage/Resources/Private/Templates/
errorFluidPartialsRootPath¶
- Datatype
- string [optional]
- Description
- Only if errorHandler == `Fluid`: Paths to Fluid Templates, Partials and Layouts in case more flexibility is needed.
- Example
EXT:sitepackage/Resources/Private/Partials/
errorFluidLayoutsRootPath¶
- Datatype
- string [optional]
- Description
- Only if errorHandler == `Fluid`: Paths to Fluid Templates, Partials and Layouts in case more flexibility is needed.
- Example
EXT:sitepackage/Resources/Private/Layouts/
errorContentSource¶
- Datatype
- string
- Description
- Only if `errorHandler: Page`: May be either an External URL or TYPO3 Page that will be fetched with curl and displayed in case of an error.
- Example
t3://page?uid=123
errorPhpClassFQCN¶
- Datatype
- string
- Description
- Only if `errorHandler: PHP`: Fully qualified class name of a custom error handler implementing
PageErrorHandlerInterface
. - Example
My\Site\Error\Handler