Re: [SMARTY] Arrays how to
| From: | baker_net | Date: | Sun, 08 May 2005 12:12:52 +0000 |
| Subject: | Re: [SMARTY] Arrays how to | ||
| References: | 1 | Groups: | php.smarty.general |
| Request: | Send a blank email to php-smarty-general+get-12594@lists.php.net to get a copy of this message | ||
> I try to view if a var declared as array contain value or came
> empty in a .tpl file. I try this:
> if ($imgArr neq ""){
> // actions
> }else{
> // others actions
> }
> But this generate a error. Some help with this ?
Hi!
Try this (in *.tpl file):
{if $imArr neq ""}
{* actions *}
{else}
{* others actions *}
{/if}
where {* ... *} is a Smarty comments - You must to write a html
code or
smarty actions in that places.
Best regards,
baker