What is Smarty?
Why use it?
Use Cases and Work Flow
Syntax Comparison
Template Inheritance
Best Practices
Crash Course
You may use the Smarty logo according to the trademark notice.
For sponsorship, advertising, news or other inquiries, contact us at:
Table of Contents
List of Examples
php.ini 文件
{block} 例子
{block} 例子
{block} 例子
{$smarty.block.child} 例子
{$smarty.block.parent} 例子
{for} 循环
max 属性
{forelse}的执行
{foreach} 循环
key变量的例子
item 和 key来嵌套使用{foreach}
index 例子
iteration 例子: is div by
iteration 例子: is even/odd by
first例子
last例子
show例子
total例子
{break} 例子
{continue} 例子
loop属性的演示例子
index 属性
index, index_next
和 index_prev 属性
iteration属性
first 和 last
loop
show 属性
total例子
options属性
values 和 ouptut
extends:来进行模板继承