Attention
TYPO3 v11 has reached end-of-life as of October 31th 2024 and is no longer being maintained. Use the version switcher on the top left of this page to select documentation for a supported version of TYPO3.
Need more time before upgrading? You can purchase Extended Long Term Support (ELTS) for TYPO3 v11 here: TYPO3 ELTS.
Debug ViewHelper <f:debug>
This ViewHelper generates a HTML dump of the tagged variable.
Examples
Simple
<f:debug>{testVariables.array}</f:debug>
foobarbazfoo
All Features
<f:debug title="My Title" maxDepth="5"
blacklistedClassNames="{0:'Tx_BlogExample_Domain_Model_Administrator'}"
blacklistedPropertyNames="{0:'posts'}"
plainText="true" ansiColors="false"
inline="true"
>
{blogs}
</f:debug>
[A HTML view of the var_dump]
Source code
Go to the source code of this ViewHelper: DebugViewHelper.php (GitHub).
Arguments
The following arguments are available for <f:
:
title
-
- Type
- string
Optional custom title for the debug output
maxDepth
-
- Type
- mixed
- Default
8
Sets the max recursion depth of the dump (defaults to 8). De- or increase the number according to your needs and memory limit.
plainText
-
- Type
- boolean
If TRUE, the dump is in plain text, if FALSE the debug output is in HTML format.
ansiColors
-
- Type
- boolean
If TRUE, ANSI color codes is added to the plaintext output, if FALSE (default) the plaintext debug output not colored.
inline
-
- Type
- boolean
If TRUE, the dump is rendered at the position of the <f:debug> tag. If FALSE (default), the dump is displayed at the top of the page.
blacklistedClassNames
-
- Type
- mixed
An array of class names (RegEx) to be filtered. Default is an array of some common class names.
blacklistedPropertyNames
-
- Type
- mixed
An array of property names and/or array keys (RegEx) to be filtered. Default is an array of some common property names.