I looked through the docs and wasn't able to find a count variable to see what file you are in using a field tag. For example, I want to detect when the first file is being looped though my custom field.

{custom_field} {if count == 0}foo{/if} bar {/custom_field}

  • Whilst there doesn't appear to be a count, the docs make reference to EE native count working, have you tried placing count in your tags ? Commented May 22, 2013 at 6:57

1 Answer 1


The count variable is 1-indexed so you need to do {if count == 1}{/if} to get the first in a loop.


Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.