I am trying to test whether a channel field is empty. I did this successfully on EE2.5 but on EE3.3.3, it gives me an error.
So, for testing purposes, I created a channel with one textarea field named “tester_text”. Here is the template:
{exp:channel:entries channel="tester"}
{if "{tester_text}" != ""}
{tester_text}
{/if}
{/exp:channel:entries}
If tester_text has text in it without an apostrophe, it works correctly. However, if there is an apostrophe, I receive this error:
Error
You have an invalid conditional in your template. Please review your conditionals for an unclosed string, invalid operators, a missing }, or a missing {/if}.
Parser State: Unexpected ‘s’ (VARIABLE); expected RD in Template “amp_site/testy” on line 3.
So, how do I test this type of field? Is this a bug or is there another way to test?
Any help appreciated! Thanks
Packet Tide owns and develops ExpressionEngine. © Packet Tide, All Rights Reserved.