You are here: Re: [SMARTY] getting value assign()'d « Smarty Templates Posts « IT news, forums, messages
Re: [SMARTY] getting value assign()'d

Posted by "Cal Henderson" on 06/02/05 08:02

Matt Warden wrote:
: $smarty->assign('myArrayCount',
count($smarty->get('myArrayCount')));

i assume you wanted the count of myArray?


if you mean you want to fetch back an already assign'd
template variable then:

$smarty->assign('myArrayCount',
count($smarty->get_template_vars('myArray')));


but really, it's very easy in smarty itself:

{$myArray|@count}


--cal

 

Navigation:

[Reply to this message]


Удаленная работа для программистов  •  Как заработать на Google AdSense  •  England, UK  •  статьи на английском  •  PHP MySQL CMS Apache Oscommerce  •  Online Business Knowledge Base  •  DVD MP3 AVI MP4 players codecs conversion help
Home  •  Search  •  Site Map  •  Set as Homepage  •  Add to Favourites

Copyright © 2005-2006 Powered by Custom PHP Programming

Сайт изготовлен в Студии Валентина Петручека
изготовление и поддержка веб-сайтов, разработка программного обеспечения, поисковая оптимизация