Skip to content

Instantly share code, notes, and snippets.

@MrMooky
Created November 16, 2016 11:04
Show Gist options
  • Save MrMooky/af9428d42a06f36eac233b3141cabebe to your computer and use it in GitHub Desktop.
Save MrMooky/af9428d42a06f36eac233b3141cabebe to your computer and use it in GitHub Desktop.
Get image from resources
<f:if condition="{page.media} == 0">
<f:then>
<v:resource.record.fal table="pages" field="media" uid="{page.pid}" as="resources">
<f:for each="{resources}" as="resource"><v:resource.image identifier="{resource.id}" width="2500" height="600c" alt="" /></f:for>
</v:resource.record.fal>
</f:then>
<f:else>
<v:resource.record.fal table="pages" field="media" uid="{page.uid}" as="resources">
<f:for each="{resources}" as="resource"><v:resource.image identifier="{resource.id}" width="2500" height="600c" alt="" /></f:for>
</v:resource.record.fal>
</f:else>
</f:if>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment