mirror of
https://github.com/smarty-php/smarty.git
synced 2025-08-05 02:44:27 +02:00
applied manual updates from Peter Morgan. he added loads of useful
crosslinks between related functions and fixed some minors.
This commit is contained in:
@@ -5,7 +5,7 @@
|
||||
<para>
|
||||
All Smarty template tags are enclosed within delimiters. By
|
||||
default, these delimiters are <literal>{</literal> and
|
||||
<literal>}</literal>, but they can be changed.
|
||||
<literal>}</literal>, but they can be <link linkend="variable.left.delimiter">changed</link>.
|
||||
</para>
|
||||
<para>
|
||||
For these examples, we will assume that you are using the default
|
||||
|
@@ -30,11 +30,11 @@
|
||||
<para>
|
||||
Both built-in functions and custom functions have the same syntax in
|
||||
the templates. Built-in functions are the inner workings of Smarty,
|
||||
such as <command>if</command>, <command>section</command> and
|
||||
<command>strip</command>. They cannot be modified. Custom functions are
|
||||
such as <link linkend="language.function.if"><command>if</command></link>, <link linkend="language.function.section"><command>section</command></link> and
|
||||
<link linkend="language.function.strip"><command>strip</command></link>. They cannot be modified. Custom functions are
|
||||
additional functions implemented via plugins. They can be modified to
|
||||
your liking, or you can add new ones. <command>html_options</command> and
|
||||
<command>html_select_date</command> are examples of custom functions.
|
||||
your liking, or you can add new ones. <link linkend="language.function.html.options"><command>html_options</command></link> and
|
||||
<link linkend="language.function.html.select.date"><command>html_select_date</command></link> are examples of custom functions.
|
||||
</para>
|
||||
</sect1>
|
||||
<!-- Keep this comment at the end of the file
|
||||
|
@@ -124,6 +124,11 @@
|
||||
]]>
|
||||
</programlisting>
|
||||
</example>
|
||||
|
||||
<para>
|
||||
See also <link linkend="config.files">Config Files</link> and
|
||||
<link linkend="language.function.config.load">Config Load</link>.
|
||||
</para>
|
||||
</sect1>
|
||||
|
||||
<!-- Keep this comment at the end of the file
|
||||
|
@@ -28,6 +28,7 @@
|
||||
]]>
|
||||
</screen>
|
||||
</example>
|
||||
<para>See also <link linkend="language.escaping">Escaping Smarty Parsing</link> </para>
|
||||
</sect1>
|
||||
|
||||
<!-- Keep this comment at the end of the file
|
||||
|
@@ -35,6 +35,7 @@
|
||||
]]>
|
||||
</programlisting>
|
||||
</example>
|
||||
<para>See also <link linkend="language.escaping">Escaping Smarty Parsing</link> </para>
|
||||
</sect1>
|
||||
|
||||
<!-- Keep this comment at the end of the file
|
||||
|
@@ -62,9 +62,9 @@
|
||||
$security_settings['MODIFIER_FUNCS']</link>-array.
|
||||
</para>
|
||||
|
||||
&designers.language-modifiers.language-modifier-cat;
|
||||
&designers.language-modifiers.language-modifier-capitalize;
|
||||
&designers.language-modifiers.language-modifier-count-characters;
|
||||
&designers.language-modifiers.language-modifier-cat;
|
||||
&designers.language-modifiers.language-modifier-count-paragraphs;
|
||||
&designers.language-modifiers.language-modifier-count-sentences;
|
||||
&designers.language-modifiers.language-modifier-count-words;
|
||||
|
@@ -67,6 +67,7 @@ Next X-Men Film, X3, Delayed.
|
||||
]]>
|
||||
</screen>
|
||||
</example>
|
||||
<para>See also <link linkend="language.modifier.lower">lower</link> <link linkend="language.modifier.upper">upper</link> </para>
|
||||
</sect1>
|
||||
<!-- Keep this comment at the end of the file
|
||||
Local variables:
|
||||
|
@@ -67,6 +67,11 @@ Cold Wave Linked to Temperatures.
|
||||
]]>
|
||||
</screen>
|
||||
</example>
|
||||
<para>See also <link linkend="language.modifier.count.paragraphs">count_paragraphs</link>
|
||||
<link linkend="language.modifier.count.sentences">count_sentences</link>
|
||||
<link linkend="language.modifier.count.words">count_words</link>
|
||||
|
||||
</para>
|
||||
</sect1>
|
||||
<!-- Keep this comment at the end of the file
|
||||
Local variables:
|
||||
|
@@ -38,6 +38,11 @@ Man is Fatally Slain. Death Causes Loneliness, Feeling of Isolation.
|
||||
]]>
|
||||
</screen>
|
||||
</example>
|
||||
<para>See also <link linkend="language.modifier.count.characters">count_characters</link>
|
||||
<link linkend="language.modifier.count.sentences">count_sentences</link>
|
||||
<link linkend="language.modifier.count.words">count_words</link>
|
||||
|
||||
</para>
|
||||
</sect1>
|
||||
<!-- Keep this comment at the end of the file
|
||||
Local variables:
|
||||
|
@@ -37,6 +37,11 @@ Two Soviet Ships Collide - One Dies. Enraged Cow Injures Farmer with Axe.
|
||||
]]>
|
||||
</screen>
|
||||
</example>
|
||||
<para>See also <link linkend="language.modifier.count.characters">count_characters</link>
|
||||
<link linkend="language.modifier.count.paragraphs">count_paragraphs</link>
|
||||
<link linkend="language.modifier.count.words">count_words</link>
|
||||
|
||||
</para>
|
||||
</sect1>
|
||||
<!-- Keep this comment at the end of the file
|
||||
Local variables:
|
||||
|
@@ -37,6 +37,12 @@ Dealers Will Hear Car Talk at Noon.
|
||||
]]>
|
||||
</screen>
|
||||
</example>
|
||||
<para>See also <link linkend="language.modifier.count.characters">count_characters</link>
|
||||
<link linkend="language.modifier.count.paragraphs">count_paragraphs</link>
|
||||
<link linkend="language.modifier.count.sentences">count_sentences</link>
|
||||
|
||||
</para>
|
||||
|
||||
</sect1>
|
||||
<!-- Keep this comment at the end of the file
|
||||
Local variables:
|
||||
|
@@ -203,8 +203,9 @@ Monday, February 5, 2001
|
||||
<note>
|
||||
<title>Programmers note</title>
|
||||
<para>
|
||||
date_format is essentially a wrapper to PHP's strftime()
|
||||
function. You may have more or less conversion specifiers available depending
|
||||
date_format is essentially a wrapper to PHP's
|
||||
<ulink url="&url.php-manual;strftime">strftime()</ulink> function.
|
||||
You may have more or less conversion specifiers available depending
|
||||
on your system's strftime() function where PHP was compiled. Check your
|
||||
system's manpage for a full list of valid specifiers.
|
||||
</para>
|
||||
|
@@ -37,7 +37,12 @@ two convicts evade noose, jury hung.
|
||||
]]>
|
||||
</screen>
|
||||
</example>
|
||||
</sect1>
|
||||
<para>
|
||||
See also <link linkend="language.modifier.upper">upper</link> and
|
||||
<link linkend="language.modifier.capitalize">Capitalize</link>.
|
||||
</para>
|
||||
</sect1>
|
||||
|
||||
<!-- Keep this comment at the end of the file
|
||||
Local variables:
|
||||
mode: sgml
|
||||
@@ -57,4 +62,4 @@ End:
|
||||
vim600: syn=xml fen fdm=syntax fdl=2 si
|
||||
vim: et tw=78 syn=sgml
|
||||
vi: ts=1 sw=1
|
||||
-->
|
||||
-->
|
||||
|
@@ -37,7 +37,12 @@ IF STRIKE ISN'T SETTLED QUICKLY IT MAY LAST A WHILE.
|
||||
]]>
|
||||
</screen>
|
||||
</example>
|
||||
</sect1>
|
||||
<para>
|
||||
See also <link linkend="language.modifier.lower">lower</link> and
|
||||
<link linkend="language.modifier.capitalize">capitalize</link>.
|
||||
</para>
|
||||
</sect1>
|
||||
|
||||
<!-- Keep this comment at the end of the file
|
||||
Local variables:
|
||||
mode: sgml
|
||||
@@ -57,4 +62,4 @@ End:
|
||||
vim600: syn=xml fen fdm=syntax fdl=2 si
|
||||
vim: et tw=78 syn=sgml
|
||||
vi: ts=1 sw=1
|
||||
-->
|
||||
-->
|
||||
|
@@ -86,7 +86,7 @@
|
||||
<sect2 id="language.variables.smarty.capture">
|
||||
<title>{$smarty.capture}</title>
|
||||
<para>
|
||||
The output captured via {capture}..{/capture} construct can be
|
||||
The output captured via <link linkend="language.function.capture">{capture}..{/capture}</link> construct can be
|
||||
accessed using {$smarty} variable. See section on
|
||||
<link linkend="language.function.capture">capture</link> for an example.
|
||||
</para>
|
||||
|
@@ -78,8 +78,13 @@ $smarty->display("db:header.tpl");
|
||||
]]>
|
||||
</programlisting>
|
||||
</example>
|
||||
<para>
|
||||
See also <link linkend="api.fetch">fetch()</link> and
|
||||
<link linkend="api.template.exists">template_exists</link>.
|
||||
</para>
|
||||
</refsect1>
|
||||
</refentry>
|
||||
|
||||
<!-- Keep this comment at the end of the file
|
||||
Local variables:
|
||||
mode: sgml
|
||||
|
@@ -61,8 +61,13 @@ echo $output;
|
||||
</programlisting>
|
||||
</example>
|
||||
</para>
|
||||
<para>
|
||||
See also <link linkend="api.display">display()</link> and
|
||||
<link linkend="api.template.exists">template_exists</link>.
|
||||
</para>
|
||||
</refsect1>
|
||||
</refentry>
|
||||
|
||||
<!-- Keep this comment at the end of the file
|
||||
Local variables:
|
||||
mode: sgml
|
||||
|
@@ -20,8 +20,12 @@
|
||||
<link linkend="advanced.features.objects">object section</link>
|
||||
of the manual for examples.
|
||||
</para>
|
||||
<para>
|
||||
See Also <link linkend="api.unregister.object">unregister_object</link>.
|
||||
</para>
|
||||
</refsect1>
|
||||
</refentry>
|
||||
|
||||
<!-- Keep this comment at the end of the file
|
||||
Local variables:
|
||||
mode: sgml
|
||||
|
@@ -14,6 +14,7 @@
|
||||
<para>
|
||||
Use this to unregister an object.
|
||||
</para>
|
||||
<para>See also <link linkend="api.register.object">register_object</link> <link linkend="advanced.features.objects">object section</link></para>
|
||||
</refsect1>
|
||||
</refentry>
|
||||
<!-- Keep this comment at the end of the file
|
||||
|
@@ -1,14 +1,16 @@
|
||||
<?xml version="1.0" encoding="iso-8859-1"?>
|
||||
<!-- $Revision$ -->
|
||||
<sect1 id="variable.error.reporting">
|
||||
<title>$error_reporting</title>
|
||||
<para>
|
||||
When this value is set to a non-null-value it's value is
|
||||
used as php's error_reporting-level inside of display() and
|
||||
fetch(). When debugging is enabled this value is ignored
|
||||
and the error-level is left untouched.
|
||||
</para>
|
||||
<sect1 id="variable.error.reporting">
|
||||
<title>$error_reporting</title>
|
||||
<para>
|
||||
When this value is set to a non-null-value it's value is used as php's
|
||||
error_reporting-level inside of <link linkend="api.display">display()</link>
|
||||
and <link linkend="api.fetch">fetch()</link>. When <link
|
||||
linkend="chapter.debugging.console">debugging</link> is enabled this value
|
||||
is ignored and the error-level is left untouched.
|
||||
</para>
|
||||
</sect1>
|
||||
|
||||
<!-- Keep this comment at the end of the file
|
||||
Local variables:
|
||||
mode: sgml
|
||||
@@ -28,4 +30,4 @@ End:
|
||||
vim600: syn=xml fen fdm=syntax fdl=2 si
|
||||
vim: et tw=78 syn=sgml
|
||||
vi: ts=1 sw=1
|
||||
-->
|
||||
-->
|
||||
|
@@ -1,12 +1,16 @@
|
||||
<?xml version="1.0" encoding="iso-8859-1"?>
|
||||
<!-- $Revision$ -->
|
||||
<sect1 id="variable.left.delimiter">
|
||||
<title>$left_delimiter</title>
|
||||
<para>
|
||||
This is the left delimiter used by the template language.
|
||||
Default is "{".
|
||||
</para>
|
||||
<sect1 id="variable.left.delimiter">
|
||||
<title>$left_delimiter</title>
|
||||
<para>
|
||||
This is the left delimiter used by the template language.
|
||||
Default is "{".
|
||||
</para>
|
||||
<para>
|
||||
See also <link linkend="variable.right.delimiter">$right_delimiter</link>.
|
||||
</para>
|
||||
</sect1>
|
||||
|
||||
<!-- Keep this comment at the end of the file
|
||||
Local variables:
|
||||
mode: sgml
|
||||
@@ -26,4 +30,4 @@ End:
|
||||
vim600: syn=xml fen fdm=syntax fdl=2 si
|
||||
vim: et tw=78 syn=sgml
|
||||
vi: ts=1 sw=1
|
||||
-->
|
||||
-->
|
||||
|
@@ -1,12 +1,16 @@
|
||||
<?xml version="1.0" encoding="iso-8859-1"?>
|
||||
<!-- $Revision$ -->
|
||||
<sect1 id="variable.right.delimiter">
|
||||
<title>$right_delimiter</title>
|
||||
<para>
|
||||
This is the right delimiter used by the template language.
|
||||
Default is "}".
|
||||
</para>
|
||||
<sect1 id="variable.right.delimiter">
|
||||
<title>$right_delimiter</title>
|
||||
<para>
|
||||
This is the right delimiter used by the template language.
|
||||
Default is "}".
|
||||
</para>
|
||||
<para>
|
||||
See also <link linkend="variable.left.delimiter">$left_delimiter</link>.
|
||||
</para>
|
||||
</sect1>
|
||||
|
||||
<!-- Keep this comment at the end of the file
|
||||
Local variables:
|
||||
mode: sgml
|
||||
@@ -26,4 +30,4 @@ End:
|
||||
vim600: syn=xml fen fdm=syntax fdl=2 si
|
||||
vim: et tw=78 syn=sgml
|
||||
vi: ts=1 sw=1
|
||||
-->
|
||||
-->
|
||||
|
@@ -10,6 +10,9 @@
|
||||
<!ENTITY url.php-accelerator 'http://www.php-accelerator.co.uk'>
|
||||
<!ENTITY url.zend 'http://www.zend.com/'>
|
||||
|
||||
<!-- to use like <ulink url="&url.php-manual;some_function"> -->
|
||||
<!ENTITY url.php-manual 'http://php.net/'>
|
||||
|
||||
<!-- The three special language constants -->
|
||||
<!ENTITY true '<constant>TRUE</constant>'>
|
||||
<!ENTITY false '<constant>FALSE</constant>'>
|
||||
|
Reference in New Issue
Block a user