to access images from content. (see codeblock below)cgsi_getimages
I only want to use the first image from the array, I have tried to use "{$image.src.0}" ,
"{$image.src.[0]}" ,
"{$image.src.first}", etc. without any luck.
This is the loop I'm using:
Code: Select all
{if !empty($entry->fields)}
{cgsi_getimages assign='imageinfo' nocontent=1}{$entry->content}{/cgsi_getimages}
{foreach from=$imageinfo item=image}
<img src="{$image.src}" class="text-left img-responsive" alt="Exhibition">
{/foreach}
{else}
........
Can someone explain to me how I can access only one image from the content with this loop?