Separated some template code from php code.

This commit is contained in:
freespace
2004-11-25 23:01:07 +00:00
parent 7fc981a638
commit 40119eab73

View File

@@ -50,8 +50,13 @@ $smarty->display("file:admin/menu.tpl"); // same as one above
$smarty->display("file:/export/templates/index.tpl");
$smarty->display("file:/path/to/my/templates/menu.tpl");
?>
{* from within Smarty template *}
]]>
</programlisting>
<para>
And from within Smarty template:
</para>
<programlisting>
<![CDATA[
{include file="file:/usr/local/share/templates/navigation.tpl"}
]]>
</programlisting>
@@ -73,8 +78,13 @@ $smarty->display("file:/path/to/my/templates/menu.tpl");
$smarty->display("file:C:/export/templates/index.tpl");
$smarty->display("file:F:/path/to/my/templates/menu.tpl");
?>
{* from within Smarty template *}
]]>
</programlisting>
<para>
And from within Smarty template:
</para>
<programlisting>
<![CDATA[
{include file="file:D:/usr/local/share/templates/navigation.tpl"}
]]>
</programlisting>
@@ -162,8 +172,13 @@ $smarty->register_resource("db", array("db_get_template",
// using resource from php script
$smarty->display("db:index.tpl");
?>
{* using resource from within Smarty template *}
]]>
</programlisting>
<para>
And from within Smarty template:
</para>
<programlisting>
<![CDATA[
{include file="db:/extras/navigation.tpl"}
]]>
</programlisting>