0

I would like to "hide" the empty fields in my admin/user email notifications. Right now it's outputting all of them when I do:

{form:fields}
{field:label} : {field:value}
{/form:fields}

I've tried using conditionals as well but nothing works.

(The Forms module was previously known as DevDemon Forms.)

1

Just found out the answer. I had to add quotation marks around the {field:value} conditional. Below is an example.

{form:fields}
{if "{field:value}" != ''}
{field:label} : {field:value}
{/if}
{/form:fields}
| improve this answer | |

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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