DEPRECATION WARNING

This documentation is not using the current rendering mechanism and is probably outdated. The extension maintainer should switch to the new system. Details on how to use the rendering mechanism can be found here.

FirstImageViewHelper

ViewHelper to return the first image of a list of images.

General properties

Name: Type: Description: Default value:
string string List of images  
separator string Separator char to explode the list ,
trim boolean Option to remove empty values true

Example

Basic

Code:

<chriwo:firstImage string="image1.jpg,image2.png"/>

Output:

image1.jpg

Get first image of semicolon list

Code:

<chriwo:firstImage string="image1.jpg;image2.png" separator=";"/>

Output:

image1.jpg