> Smarty模板引擎中文在线手册 > Objects

Objects

Properties of objects assigned from PHP can be referenced by specifying the property name after the '->' symbol.

Example 4-4. Accessing object properties

name: {$person->name}<br>
email: {$person->email}<br>

OUTPUT:

name: Zaphod Beeblebrox<br>
email: zaphod@slartibartfast.com<br>
上一篇: