x1nick Posted December 6, 2011 Share Posted December 6, 2011 I have the following, which I thought wouldnt work but gave it a go. {foreach from=$this->toolbar_items key=id item=params} {$this->partial('toolbar/item.tpl', array('id' => id, 'params' => params))} {/foreach} Essentially this would output <?php foreach ($this->toolbar_items as $id => $params): ?> <?php echo $this->partial('toolbar/item.tpl', array('id' => $id, 'params' => $params)) ?> <?php endforeach ?> Is this even possible? I must do this a fair few times in all my projects so need to be able to do this! Cheers Link to comment https://forums.phpfreaks.com/topic/252624-smarty-and-zend-partials/ Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.