Answers for "twig variable is defined"

1

twig variable is defined

{% if varname is defined %}
	Variable exists.
{% endif %}
Posted by: Guest on February-17-2021
0

twig variable is not defined

{% if not (varname is defined) %}
	Variable does not exist.
{% endif %}
Posted by: Guest on February-17-2021

Browse Popular Code Answers by Language