ExampleViewHelper extends AbstractViewHelper
This class is the implementation of a Fluid ViewHelper.
View this class in the TYPO3 ViewHelper reference: <.typo3.cms.styleguide.s.example>
FinalYes
ViewHelper for rendering a code example
Examples
Simple:
sg:exampleyour code</sg:example>
All options:
<sg:example codePreview="true" codeLanguage="html" customCode="{codeSnippet}" decodeEntities="true">your code</sg:example>
Table of Contents
Properties
- $escapeChildren : bool
- $escapeOutput : bool
- $pageRenderer : PageRenderer
Methods
- initializeArguments() : void
- injectPageRenderer() : void
- render() : string
Properties
$escapeChildren
protected
bool
$escapeChildren
= false
$escapeOutput
protected
bool
$escapeOutput
= false
$pageRenderer
protected
PageRenderer
$pageRenderer
Methods
initializeArguments()
public
initializeArguments() : void
injectPageRenderer()
public
injectPageRenderer(PageRenderer $pageRenderer) : void
Parameters
- $pageRenderer : PageRenderer
render()
public
render() : string