{foreach item='button' from=$buttons} {if $button.type == 'action'} {cssbutton->sub name=$button.name id=$button.name value=$button.value string=$button.title confirm=$button.confirm script=$button.script} {elseif $button.type == 'click'} {cssbutton->click script=$button.script string=$button.title} {/if} {/foreach}