{if not isset} Smarty

Rami Dabain picture Rami Dabain · May 10, 2011 · Viewed 52.7k times · Source

what is the code for smarty for if (!isset($var)){ ?

if using {if $x eq '5'} when $x is not defined in smarty , it gives an error function call 'get_template_vars' is unknown or deprecated. . this is what i believe so far as i lost hope in trying to know where did this error come from !

Thanky you .

Answer

Timofey Stolbov picture Timofey Stolbov · May 10, 2011
{if ! isset($var)}
body must be at least 30 characters. :)
{/if}