其实用了以后发现功能还不错 ,例如CACHE功能
以后用到的也就是那几个 例如
<{if $list=="是" }>显示<{/if}>
<{foreach =$array item=item key=key}>
<{$key}>
<{/foreache}>
以后用到的也就是那几个 例如
<{if $list=="是" }>显示<{/if}>
<{foreach =$array item=item key=key}>
<{$key}>
<{/foreache}>
扩展性强吧,网上有Smarty 的 DW 插件下载的。
An example of a section loop:{section name=outer loop=$FirstName}
{if %outer.index% is odd by 2}
{%outer.rownum%} . {$FirstName[outer]} {$LastName[outer]}
{else}
{%outer.rownum%} * {$FirstName[outer]} {$LastName[outer]}
{/if}
{sectionelse}
none
{/section}An example of section looped key values:{section name=sec1 loop=$contacts}
phone: {$contacts[sec1].phone}<br>
fax: {$contacts[sec1].fax}<br>
cell: {$contacts[sec1].cell}<br>
{/section}
<p>testing strip tags
{strip}
<table border=0>
<tr>
<td>
<A HREF="{$SCRIPT_NAME}">
<font color="red">This is a test </font>
</A>
</td>
</tr>
</table>
{/strip}</PRE>This is an example of the html_select_date function:<form>
{html_select_date start_year=1998 end_year=2010}
</form>This is an example of the html_select_time function:<form>
{html_select_time use_24_hours=false}
</form>This is an example of the html_options function:<form>
<select name=states>
{html_options values=$option_values selected=$option_selected output=$option_output}
</select>
</form>这模板的规律在那里呢?
感觉已经超出模板的一般概念