HtmlViewHelper extends AbstractViewHelper

ViewHelper

This class is the implementation of a Fluid ViewHelper.

View this class in the TYPO3 ViewHelper reference: <f:transform.html>

FinalYes

Transforms HTML and substitutes internal link scheme aspects.

Examples

Default parameters

::

<f:transform.html selector="a.href" onFailure="removeEnclosure"> Home </f:transform.html>

Output::

<a href="https://example.com/home" class="home">Home</a>

Inline notation

::

{content -> f:transform.html(selector:'a.href', onFailure:'removeEnclosure')}

Table of Contents

Constants

MAP_ON_FAILURE  = ['' => 0, 'null' => 0, 'removeTag' => \TYPO3\CMS\Frontend\Html\HtmlWorker::REMOVE_TAG_ON_FAILURE, 'removeAttr' => \TYPO3\CMS\Frontend\Html\HtmlWorker::REMOVE_ATTR_ON_FAILURE, 'removeEnclosure' => \TYPO3\CMS\Frontend\Html\HtmlWorker::REMOVE_ENCLOSURE_ON_FAILURE]

Properties

$escapeChildren  : bool
$escapeOutput  : bool

Methods

initializeArguments()  : void
render()  : string

Constants

MAP_ON_FAILURE

protected mixed MAP_ON_FAILURE = ['' => 0, 'null' => 0, 'removeTag' => \TYPO3\CMS\Frontend\Html\HtmlWorker::REMOVE_TAG_ON_FAILURE, 'removeAttr' => \TYPO3\CMS\Frontend\Html\HtmlWorker::REMOVE_ATTR_ON_FAILURE, 'removeEnclosure' => \TYPO3\CMS\Frontend\Html\HtmlWorker::REMOVE_ENCLOSURE_ON_FAILURE]

Properties

$escapeChildren

protected bool $escapeChildren = false

$escapeOutput

protected bool $escapeOutput = false

Methods

initializeArguments()

public initializeArguments() : void

render()

public render() : string
Return values
string

transformed markup


        
On this page

Search results