diff --git a/docs/en/designers/chapter-debugging-console.xml b/docs/en/designers/chapter-debugging-console.xml index 61bd41fe..78178b5e 100644 --- a/docs/en/designers/chapter-debugging-console.xml +++ b/docs/en/designers/chapter-debugging-console.xml @@ -1,40 +1,40 @@ - - Debugging Console - - There is a debugging console included with Smarty. The console informs you - of all the included templates, assigned variables and config file variables - for the current invocation of the template. A template named "debug.tpl" is - included with the distribution of Smarty which controls the formatting of - the console. Set $debugging to true in Smarty, and if needed set $debug_tpl - to the template resource path for debug.tpl (this is in SMARTY_DIR by - default.) When you load the page, a javascript console window should pop up - and give you the names of all the included templates and assigned variables - for the current page. To see the available variables for a particular - templates, see the {debug} - template function. To disable the debugging console, set $debugging to - false. You can also temporarily turn on the debugging console by putting - SMARTY_DEBUG in the URL if you enable this option with $debugging_ctrl. - - - Technical Note - - The debugging console does not work when you use the fetch() - API, only when using display(). It is a set of javascript statements added - to the very bottom of the generated template. If you do not like javascript, - you can edit the debug.tpl template to format the output however you like. - Debug data is not cached and debug.tpl info is not included in the output of - the debug console. - - - - - The load times of each template and config file are in seconds, or - fractions thereof. - - + + Debugging Console + + There is a debugging console included with Smarty. The console informs you + of all the included templates, assigned variables and config file variables + for the current invocation of the template. A template named "debug.tpl" is + included with the distribution of Smarty which controls the formatting of + the console. Set $debugging to true in Smarty, and if needed set $debug_tpl + to the template resource path for debug.tpl (this is in SMARTY_DIR by + default.) When you load the page, a javascript console window should pop up + and give you the names of all the included templates and assigned variables + for the current page. To see the available variables for a particular + templates, see the {debug} + template function. To disable the debugging console, set $debugging to + false. You can also temporarily turn on the debugging console by putting + SMARTY_DEBUG in the URL if you enable this option with $debugging_ctrl. + + + Technical Note + + The debugging console does not work when you use the fetch() + API, only when using display(). It is a set of javascript statements added + to the very bottom of the generated template. If you do not like javascript, + you can edit the debug.tpl template to format the output however you like. + Debug data is not cached and debug.tpl info is not included in the output of + the debug console. + + + + + The load times of each template and config file are in seconds, or + fractions thereof. + + - - Config Files - - Config files are handy for designers to manage global template - variables from one file. One example is template colors. Normally if - you wanted to change the color scheme of an application, you would have - to go through each and every template file and change the colors. With - a config file, the colors can be kept in one place, and only one file - needs to be updated. - - - Example of config file syntax - + + Config Files + + Config files are handy for designers to manage global template + variables from one file. One example is template colors. Normally if + you wanted to change the color scheme of an application, you would have + to go through each and every template file and change the colors. With + a config file, the colors can be kept in one place, and only one file + needs to be updated. + + + Example of config file syntax + + - - - Values of config file variables can be in quotes, but not necessary. - You can use either single or double quotes. If you have a value that - spans more than one line, enclose the entire value with triple quotes - ("""). You can put comments into config files by any syntax that is not - a valid config file syntax. We recommend using a # - (hash) at the beginning of the line. - - - This config file example has two sections. Section names are enclosed in - brackets []. Section names can be arbitrary strings not containing - [ or ] symbols. The four variables - at the top are global variables, or variables not within a section. - These variables are always loaded from the config file. If a particular - section is loaded, then the global variables and the variables from that - section are also loaded. If a variable exists both as a global and in a - section, the section variable is used. If you name two variables the - same within a section, the last one will be used. - - - Config files are loaded into templates with the built-in function - config_load. - - - You can hide variables or entire sections by prepending the variable - name or section name with a period. This is useful if your application - reads the config files and gets sensitive data from them that the - template engine does not need. If you have third parties doing template - editing, you can be certain that they cannot read sensitive data from - the config file by loading it into the template. - - +]]> + + + + Values of config file variables can be in quotes, but not necessary. + You can use either single or double quotes. If you have a value that + spans more than one line, enclose the entire value with triple quotes + ("""). You can put comments into config files by any syntax that is not + a valid config file syntax. We recommend using a # + (hash) at the beginning of the line. + + + This config file example has two sections. Section names are enclosed in + brackets []. Section names can be arbitrary strings not containing + [ or ] symbols. The four variables + at the top are global variables, or variables not within a section. + These variables are always loaded from the config file. If a particular + section is loaded, then the global variables and the variables from that + section are also loaded. If a variable exists both as a global and in a + section, the section variable is used. If you name two variables the + same within a section, the last one will be used. + + + Config files are loaded into templates with the built-in function + config_load. + + + You can hide variables or entire sections by prepending the variable + name or section name with a period. This is useful if your application + reads the config files and gets sensitive data from them that the + template engine does not need. If you have third parties doing template + editing, you can be certain that they cannot read sensitive data from + the config file by loading it into the template. + + - - Basic Syntax - - All Smarty template tags are enclosed within delimiters. By - default, these delimiters are { and - }, but they can be changed. - - - For these examples, we will assume that you are using the default - delimiters. In Smarty, all content outside of delimiters is displayed as - static content, or unchanged. When Smarty encounters template tags, it - attempts to interpret them, and displays the appropriate output in their - place. - + + Basic Syntax + + All Smarty template tags are enclosed within delimiters. By + default, these delimiters are { and + }, but they can be changed. + + + For these examples, we will assume that you are using the default + delimiters. In Smarty, all content outside of delimiters is displayed as + static content, or unchanged. When Smarty encounters template tags, it + attempts to interpret them, and displays the appropriate output in their + place. + -&designers.language-basic-syntax.language-syntax-comments; - -&designers.language-basic-syntax.language-syntax-functions; - -&designers.language-basic-syntax.language-syntax-attributes; -&designers.language-basic-syntax.language-syntax-quotes; -&designers.language-basic-syntax.language-math; - -&designers.language-basic-syntax.language-escaping; - + &designers.language-basic-syntax.language-syntax-comments; + &designers.language-basic-syntax.language-syntax-functions; + &designers.language-basic-syntax.language-syntax-attributes; + &designers.language-basic-syntax.language-syntax-quotes; + &designers.language-basic-syntax.language-math; + &designers.language-basic-syntax.language-escaping; + + - - Built-in Functions - - Smarty comes with several built-in functions. Built-in functions - are integral to the template language. You cannot create custom - functions with the same names, nor can you modify built-in functions. - -&designers.language-builtin-functions.language-function-capture; -&designers.language-builtin-functions.language-function-config-load; -&designers.language-builtin-functions.language-function-foreach; -&designers.language-builtin-functions.language-function-include; -&designers.language-builtin-functions.language-function-include-php; -&designers.language-builtin-functions.language-function-insert; -&designers.language-builtin-functions.language-function-if; -&designers.language-builtin-functions.language-function-ldelim; -&designers.language-builtin-functions.language-function-literal; -&designers.language-builtin-functions.language-function-php; -&designers.language-builtin-functions.language-function-section; -&designers.language-builtin-functions.language-function-strip; + + Built-in Functions + + Smarty comes with several built-in functions. Built-in functions + are integral to the template language. You cannot create custom + functions with the same names, nor can you modify built-in functions. + + + &designers.language-builtin-functions.language-function-capture; + &designers.language-builtin-functions.language-function-config-load; + &designers.language-builtin-functions.language-function-foreach; + &designers.language-builtin-functions.language-function-include; + &designers.language-builtin-functions.language-function-include-php; + &designers.language-builtin-functions.language-function-insert; + &designers.language-builtin-functions.language-function-if; + &designers.language-builtin-functions.language-function-ldelim; + &designers.language-builtin-functions.language-function-literal; + &designers.language-builtin-functions.language-function-php; + &designers.language-builtin-functions.language-function-section; + &designers.language-builtin-functions.language-function-strip; + \ No newline at end of file +--> diff --git a/docs/en/designers/language-combining-modifiers.xml b/docs/en/designers/language-combining-modifiers.xml index d9d4229a..eab0a778 100644 --- a/docs/en/designers/language-combining-modifiers.xml +++ b/docs/en/designers/language-combining-modifiers.xml @@ -1,15 +1,15 @@ - - Combining Modifiers - - You can apply any number of modifiers to a variable. They will be - applied in the order they are combined, from left to right. They must - be separated with a | (pipe) character. - - - combining modifiers - + + Combining Modifiers + + You can apply any number of modifiers to a variable. They will be + applied in the order they are combined, from left to right. They must + be separated with a | (pipe) character. + + + combining modifiers + - - - The above example will output: - - + + + The above example will output: + + - - - + + + - - Custom Functions - - Smarty comes with several custom functions that you can - use in the templates. - -&designers.language-custom-functions.language-function-assign; -&designers.language-custom-functions.language-function-counter; -&designers.language-custom-functions.language-function-cycle; -&designers.language-custom-functions.language-function-debug; -&designers.language-custom-functions.language-function-eval; -&designers.language-custom-functions.language-function-fetch; -&designers.language-custom-functions.language-function-html-checkboxes; -&designers.language-custom-functions.language-function-html-image; -&designers.language-custom-functions.language-function-html-options; -&designers.language-custom-functions.language-function-html-radios; -&designers.language-custom-functions.language-function-html-select-date; -&designers.language-custom-functions.language-function-html-select-time; -&designers.language-custom-functions.language-function-html-table; -&designers.language-custom-functions.language-function-math; -&designers.language-custom-functions.language-function-mailto; -&designers.language-custom-functions.language-function-popup-init; -&designers.language-custom-functions.language-function-popup; -&designers.language-custom-functions.language-function-textformat; + + Custom Functions + + Smarty comes with several custom functions that you can + use in the templates. + + + &designers.language-custom-functions.language-function-assign; + &designers.language-custom-functions.language-function-counter; + &designers.language-custom-functions.language-function-cycle; + &designers.language-custom-functions.language-function-debug; + &designers.language-custom-functions.language-function-eval; + &designers.language-custom-functions.language-function-fetch; + &designers.language-custom-functions.language-function-html-checkboxes; + &designers.language-custom-functions.language-function-html-image; + &designers.language-custom-functions.language-function-html-options; + &designers.language-custom-functions.language-function-html-radios; + &designers.language-custom-functions.language-function-html-select-date; + &designers.language-custom-functions.language-function-html-select-time; + &designers.language-custom-functions.language-function-html-table; + &designers.language-custom-functions.language-function-math; + &designers.language-custom-functions.language-function-mailto; + &designers.language-custom-functions.language-function-popup-init; + &designers.language-custom-functions.language-function-popup; + &designers.language-custom-functions.language-function-textformat; + - - Variables - - Smarty has several different types of variables. The type of the variable - depends on what symbol it is prefixed with (or enclosed within). - - - - Variables in Smarty can be either displayed directly or used as arguments - for function attributes and modifiers, inside conditional expressions, - etc. To print a variable, simply enclose it in the delimiters so that it - is the only thing contained between them. Examples: - + + Variables + + Smarty has several different types of variables. The type of the variable + depends on what symbol it is prefixed with (or enclosed within). + + + Variables in Smarty can be either displayed directly or used as arguments + for function attributes and modifiers, inside conditional expressions, + etc. To print a variable, simply enclose it in the delimiters so that it + is the only thing contained between them. Examples: + ]]> - - + + -&designers.language-variables.language-assigned-variables; + &designers.language-variables.language-assigned-variables; + &designers.language-variables.language-config-variables; + &designers.language-variables.language-variables-smarty; -&designers.language-variables.language-config-variables; - -&designers.language-variables.language-variables-smarty;