IconForResourceViewHelper extends AbstractViewHelper

ViewHelper

This class is the implementation of a Fluid ViewHelper.

View this class in the TYPO3 ViewHelper reference: <core:iconforresource>

FinalYes

Displays icon for a FAL resource (file or folder means a :php:`TYPO3\CMS\Core\Resource\ResourceInterface`).

Examples

Default::

<core:iconForResource resource="{file.resource}" />

Output::

<span class="t3js-icon icon icon-size-small icon-state-default icon-mimetypes-text-html" data-identifier="mimetypes-text-html">
    <span class="icon-markup">
        <img src="/typo3/sysext/core/Resources/Public/Icons/T3Icons/mimetypes/mimetypes-text-html.svg" width="16" height="16">
    </span>
</span>

Table of Contents

Properties

$escapeOutput  : bool
ViewHelper returns HTML, thus we need to disable output escaping

Methods

initializeArguments()  : void
render()  : string

Properties

$escapeOutput

ViewHelper returns HTML, thus we need to disable output escaping

protected bool $escapeOutput = false

Methods

initializeArguments()

public initializeArguments() : void

render()

public render() : string
Return values
string

        
On this page

Search results