* some wz

* no tab
* add Cdata section
This commit is contained in:
yannick
2005-05-10 20:54:42 +00:00
parent aeab0151bf
commit 9d92dc1613
6 changed files with 412 additions and 383 deletions

View File

@@ -59,11 +59,14 @@
<example>
<title>function include</title>
<programlisting>
<![CDATA[
{include file="header.tpl"}
{* body of template goes here *}
{include file="footer.tpl"}</programlisting>
{include file="footer.tpl"}
]]>
</programlisting>
</example>
<para>
You can also pass variables to included templates as attributes.
@@ -75,11 +78,14 @@
<example>
<title>function include passing variables</title>
<programlisting>
<![CDATA[
{include file="header.tpl" title="Main Menu" table_bgcolor="#c0c0c0"}
{* body of template goes here *}
{include file="footer.tpl" logo="http://my.example.com/logo.gif"}</programlisting>
{include file="footer.tpl" logo="http://my.example.com/logo.gif"}
]]>
</programlisting>
</example>
<para>
Use the syntax for <link
@@ -89,6 +95,7 @@
<example>
<title>function include template resource examples</title>
<programlisting>
<![CDATA[
{* absolute filepath *}
{include file="/usr/local/include/templates/header.tpl"}
@@ -99,9 +106,17 @@
{include file="file:C:/www/pub/templates/header.tpl"}
{* include from template resource named "db" *}
{include file="db:header.tpl"}</programlisting>
{include file="db:header.tpl"}
]]>
</programlisting>
</example>
<para>See also <link linkend="language.function.include.php">{include_php}</link>, <link linkend="language.function.php">{php}</link> <link linkend="template.resources">Template Resources</link> and <link linkend="tips.componentized.templates">Componentized Templates</link></para>
<para>
See also
<link linkend="language.function.include.php">{include_php}</link>,
<link linkend="language.function.php">{php}</link>,
<link linkend="template.resources">Template Resources</link> and
<link linkend="tips.componentized.templates">Componentized Templates</link>.
</para>
</sect1>
<!-- Keep this comment at the end of the file
Local variables:

View File

@@ -35,7 +35,10 @@
]]>
</programlisting>
</example>
<para>See also <link linkend="language.escaping">Escaping Smarty Parsing</link> </para>
<para>
See also
<link linkend="language.escaping">Escaping Smarty Parsing</link>.
</para>
</sect1>
<!-- Keep this comment at the end of the file

View File

@@ -11,13 +11,21 @@
<example>
<title>php tags</title>
<programlisting>
<![CDATA[
{php}
// including a php script directly
// from the template.
include("/path/to/display_weather.php");
{/php}</programlisting>
{/php}
]]>
</programlisting>
</example>
<para>See also <link linkend="language.function.include.php">{include_php}</link>, <link linkend="language.function.include">{include}</link> and <link linkend="tips.componentized.templates">Componentized Templates</link></para>
<para>
See also
<link linkend="language.function.include.php">{include_php}</link>,
<link linkend="language.function.include">{include}</link> and
<link linkend="tips.componentized.templates">Componentized Templates</link>.
</para>
</sect1>
<!-- Keep this comment at the end of the file
Local variables:

View File

@@ -40,13 +40,16 @@
</tr>
</table>
{/strip}
OUTPUT:
<table border=0><tr><td><A HREF="http://my.example.com"><font color="red">This is a test</font></A></td></tr></table>
]]>
</programlisting>
<para>
The above example will output:
</para>
<screen>
<![CDATA[
<table border=0><tr><td><A HREF="http://my.example.com"><font color="red">This is a test</font></A></td></tr></table>
]]>
</screen>
</example>
<para>
Notice that in the above example, all the lines begin and end