Skip to content

Instantly share code, notes, and snippets.

@keithmancuso
Last active August 29, 2015 14:03
Show Gist options
  • Star 1 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save keithmancuso/cc2e933491bb9d7afcc3 to your computer and use it in GitHub Desktop.
Save keithmancuso/cc2e933491bb9d7afcc3 to your computer and use it in GitHub Desktop.
if entry
{# for regular fields #}
{% if entry.fieldHandle %}
{{ entry.fieldHandle}}
{% else %}
{{ global.fieldHandle}}
{% endif %}
{# for array fields (entries, assets, etc) #}
{% if entry.fieldHandle |length %}
{{ entry.fieldHandle}}
{% else %}
{{ global.fieldHandle}}
{% endif %}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment