mirror of
https://github.com/smarty-php/smarty.git
synced 2025-08-07 03:44:26 +02:00
another example
This commit is contained in:
@@ -38,11 +38,17 @@
|
||||
if($foo == $bar){
|
||||
echo 'This will come out in the template';
|
||||
}
|
||||
|
||||
$this->assign('varX','Strawberry');
|
||||
|
||||
{/php}
|
||||
<strong>{$varX}</strong> is my fav ice cream
|
||||
]]>
|
||||
</programlisting>
|
||||
<para>The following seriously NOT recommended as its in the template scope</para>
|
||||
<programlisting
|
||||
<![CDATA[
|
||||
{php}
|
||||
print_r($some_array);
|
||||
{/php}
|
||||
]]>
|
||||
</programlisting>
|
||||
</example>
|
||||
|
Reference in New Issue
Block a user