diff options
| author | monte.ohrt <monte.ohrt@localhost> | 2010-08-17 15:39:51 +0000 |
|---|---|---|
| committer | monte.ohrt <monte.ohrt@localhost> | 2010-08-17 15:39:51 +0000 |
| commit | 21d507a5cbd165abbdac2ca138f7344bba3e0aab (patch) | |
| tree | 0a13e8be855e7bc92a66249270dce8bd656b352f | |
| parent | ad921936b0e840c82eec99ed188dcada02a6891e (diff) | |
| download | smarty-21d507a5cbd165abbdac2ca138f7344bba3e0aab.tar.gz smarty-21d507a5cbd165abbdac2ca138f7344bba3e0aab.tar.bz2 smarty-21d507a5cbd165abbdac2ca138f7344bba3e0aab.zip | |
fix formatting
97 files changed, 1357 insertions, 1262 deletions
diff --git a/libs/Smarty.class.php b/libs/Smarty.class.php index 62397dee..4880d245 100644 --- a/libs/Smarty.class.php +++ b/libs/Smarty.class.php @@ -760,6 +760,9 @@ class Smarty extends Smarty_Internal_Data { } } +/** + * Autoloader + */ function smartyAutoload($class) { $_class = strtolower($class); @@ -768,11 +771,16 @@ function smartyAutoload($class) } } +/** + * Smarty exception class + */ Class SmartyException extends Exception { } +/** + * Smarty compiler exception class + */ Class SmartyCompilerException extends SmartyException { } - ?>
\ No newline at end of file diff --git a/libs/plugins/block.php.php b/libs/plugins/block.php.php index 7e907bfe..84a0275e 100644 --- a/libs/plugins/block.php.php +++ b/libs/plugins/block.php.php @@ -1,21 +1,21 @@ <?php /** -* Smarty plugin to execute PHP code -* -* @package Smarty -* @subpackage PluginsBlock -* @author Uwe Tews -*/ + * Smarty plugin to execute PHP code + * + * @package Smarty + * @subpackage PluginsBlock + * @author Uwe Tews + */ /** -* Smarty {php}{/php} block plugin -* -* @param string $content contents of the block -* @param object $smarty Smarty object -* @param boolean $ &$repeat repeat flag -* @param object $template template object -* @return string content re-formatted -*/ + * Smarty {php}{/php} block plugin + * + * @param string $content contents of the block + * @param object $smarty Smarty object + * @param boolean $ &$repeat repeat flag + * @param object $template template object + * @return string content re-formatted + */ function smarty_block_php($params, $content, $smarty, &$repeat, $template) { if (!$smarty->allow_php_tag) { @@ -24,4 +24,5 @@ function smarty_block_php($params, $content, $smarty, &$repeat, $template) eval($content); return ''; } + ?>
\ No newline at end of file diff --git a/libs/plugins/block.textformat.php b/libs/plugins/block.textformat.php index f578bfb9..733f6e23 100644 --- a/libs/plugins/block.textformat.php +++ b/libs/plugins/block.textformat.php @@ -1,37 +1,37 @@ <?php /** -* Smarty plugin to format text blocks -* -* @package Smarty -* @subpackage PluginsBlock -*/ + * Smarty plugin to format text blocks + * + * @package Smarty + * @subpackage PluginsBlock + */ /** -* Smarty {textformat}{/textformat} block plugin -* -* Type: block function<br> -* Name: textformat<br> -* Purpose: format text a certain way with preset styles -* or custom wrap/indent settings<br> -* -* @link http://smarty.php.net/manual/en/language.function.textformat.php {textformat} - (Smarty online manual) -* @param array $params parameters -* <pre> -* Params: style: string (email) -* indent: integer (0) -* wrap: integer (80) -* wrap_char string ("\n") -* indent_char: string (" ") -* wrap_boundary: boolean (true) -* </pre> -* @author Monte Ohrt <monte at ohrt dot com> -* @param string $content contents of the block -* @param object $smarty Smarty object -* @param boolean &$repeat repeat flag -* @param object $template template object -* @return string content re-formatted -*/ + * Smarty {textformat}{/textformat} block plugin + * + * Type: block function<br> + * Name: textformat<br> + * Purpose: format text a certain way with preset styles + * or custom wrap/indent settings<br> + * + * @link http://smarty.php.net/manual/en/language.function.textformat.php {textformat} + * (Smarty online manual) + * @param array $params parameters + * <pre> + * Params: style: string (email) + * indent: integer (0) + * wrap: integer (80) + * wrap_char string ("\n") + * indent_char: string (" ") + * wrap_boundary: boolean (true) + * </pre> + * @author Monte Ohrt <monte at ohrt dot com> + * @param string $content contents of the block + * @param object $smarty Smarty object + * @param boolean &$repeat repeat flag + * @param object $template template object + * @return string content re-formatted + */ function smarty_block_textformat($params, $content, $smarty, &$repeat, $template) { if (is_null($content)) { @@ -100,4 +100,4 @@ function smarty_block_textformat($params, $content, $smarty, &$repeat, $template return $assign ? $template->assign($assign, $_output) : $_output; } -?> +?>
\ No newline at end of file diff --git a/libs/plugins/function.counter.php b/libs/plugins/function.counter.php index 7ad64807..e2ce8059 100644 --- a/libs/plugins/function.counter.php +++ b/libs/plugins/function.counter.php @@ -5,7 +5,6 @@ * @subpackage PluginsFunction */ - /** * Smarty {counter} function plugin * @@ -74,4 +73,5 @@ function smarty_function_counter($params, $smarty) return $retval; } + ?>
\ No newline at end of file diff --git a/libs/plugins/function.cycle.php b/libs/plugins/function.cycle.php index 2b616d11..5d976456 100644 --- a/libs/plugins/function.cycle.php +++ b/libs/plugins/function.cycle.php @@ -1,6 +1,7 @@ <?php /** * Smarty plugin + * * @package Smarty * @subpackage PluginsFunction */ @@ -41,6 +42,7 @@ * @param Smarty * @return string|null */ + function smarty_function_cycle($params, $smarty) { static $cycle_vars; @@ -100,4 +102,5 @@ function smarty_function_cycle($params, $smarty) return $retval; } + ?>
\ No newline at end of file diff --git a/libs/plugins/function.fetch.php b/libs/plugins/function.fetch.php index 391ff1bb..0a511830 100644 --- a/libs/plugins/function.fetch.php +++ b/libs/plugins/function.fetch.php @@ -1,11 +1,11 @@ <?php /** * Smarty plugin + * * @package Smarty * @subpackage PluginsFunction */ - /** * Smarty {fetch} plugin * @@ -214,4 +214,4 @@ function smarty_function_fetch($params, $smarty, $template) } } -?> +?>
\ No newline at end of file diff --git a/libs/plugins/function.html_checkboxes.php b/libs/plugins/function.html_checkboxes.php index ac72f3fd..328faf44 100644 --- a/libs/plugins/function.html_checkboxes.php +++ b/libs/plugins/function.html_checkboxes.php @@ -1,11 +1,11 @@ <?php /** * Smarty plugin + * * @package Smarty * @subpackage PluginsFunction */ - /** * Smarty {html_checkboxes} function plugin * @@ -142,4 +142,4 @@ function smarty_function_html_checkboxes_output($name, $value, $output, $selecte return $_output; } -?> +?>
\ No newline at end of file diff --git a/libs/plugins/function.html_image.php b/libs/plugins/function.html_image.php index be31b18e..e2714a67 100644 --- a/libs/plugins/function.html_image.php +++ b/libs/plugins/function.html_image.php @@ -1,39 +1,39 @@ <?php /** -* Smarty plugin -* -* @package Smarty -* @subpackage PluginsFunction -*/ + * Smarty plugin + * + * @package Smarty + * @subpackage PluginsFunction + */ /** -* Smarty {html_image} function plugin -* -* Type: function<br> -* Name: html_image<br> -* Date: Feb 24, 2003<br> -* Purpose: format HTML tags for the image<br> -* Examples: {html_image file="/images/masthead.gif"} -* Output: <img src="/images/masthead.gif" width=400 height=23> -* -* @link http://smarty.php.net/manual/en/language.function.html.image.php {html_image} - (Smarty online manual) -* @author Monte Ohrt <monte at ohrt dot com> -* @author credits to Duda <duda@big.hu> -* @version 1.0 -* @param array $params parameters -* Input:<br> -* - file = file (and path) of image (required) -* - height = image height (optional, default actual height) -* - width = image width (optional, default actual width) -* - basedir = base directory for absolute paths, default -* is environment variable DOCUMENT_ROOT -* - path_prefix = prefix for path output (optional, default empty) -* @param object $smarty Smarty object -* @param object $template template object -* @return string -* @uses smarty_function_escape_special_chars() -*/ + * Smarty {html_image} function plugin + * + * Type: function<br> + * Name: html_image<br> + * Date: Feb 24, 2003<br> + * Purpose: format HTML tags for the image<br> + * Examples: {html_image file="/images/masthead.gif"} + * Output: <img src="/images/masthead.gif" width=400 height=23> + * + * @link http://smarty.php.net/manual/en/language.function.html.image.php {html_image} + * (Smarty online manual) + * @author Monte Ohrt <monte at ohrt dot com> + * @author credits to Duda <duda@big.hu> + * @version 1.0 + * @param array $params parameters + * Input:<br> + * - file = file (and path) of image (required) + * - height = image height (optional, default actual height) + * - width = image width (optional, default actual width) + * - basedir = base directory for absolute paths, default + * is environment variable DOCUMENT_ROOT + * - path_prefix = prefix for path output (optional, default empty) + * @param object $smarty Smarty object + * @param object $template template object + * @return string + * @uses smarty_function_escape_special_chars() + */ function smarty_function_html_image($params, $smarty, $template) { require_once(SMARTY_PLUGINS_DIR . 'shared.escape_special_chars.php'); diff --git a/libs/plugins/function.html_options.php b/libs/plugins/function.html_options.php index 85b05f7d..a4725809 100644 --- a/libs/plugins/function.html_options.php +++ b/libs/plugins/function.html_options.php @@ -1,35 +1,34 @@ <?php /** -* Smarty plugin -* -* @package Smarty -* @subpackage PluginsFunction -*/ + * Smarty plugin + * + * @package Smarty + * @subpackage PluginsFunction + */ /** -* Smarty {html_options} function plugin -* -* Type: function<br> -* Name: html_options<br> -* Purpose: Prints the list of <option> tags generated from -* the passed parameters -* -* @link http://smarty.php.net/manual/en/language.function.html.options.php {html_image} - (Smarty online manual) -* @author Monte Ohrt <monte at ohrt dot com> -* @param array $params parameters -* Input:<br> -* - name (optional) - string default "select" -* - values (required if no options supplied) - array -* - options (required if no values supplied) - associative array -* - selected (optional) - string default not set -* - output (required if not options supplied) - array -* @param object $smarty Smarty object -* @param object $template template object -* @return string -* @uses smarty_function_escape_special_chars() -*/ - + * Smarty {html_options} function plugin + * + * Type: function<br> + * Name: html_options<br> + * Purpose: Prints the list of <option> tags generated from + * the passed parameters + * + * @link http://smarty.php.net/manual/en/language.function.html.options.php {html_image} + * (Smarty online manual) + * @author Monte Ohrt <monte at ohrt dot com> + * @param array $params parameters + * Input:<br> + * - name (optional) - string default "select" + * - values (required if no options supplied) - array + * - options (required if no values supplied) - associative array + * - selected (optional) - string default not set + * - output (required if not options supplied) - array + * @param object $smarty Smarty object + * @param object $template template object + * @return string + * @uses smarty_function_escape_special_chars() + */ function smarty_function_html_options($params, $smarty, $template) { require_once(SMARTY_PLUGINS_DIR . 'shared.escape_special_chars.php'); @@ -119,4 +118,4 @@ function smarty_function_html_options_optgroup($key, $values, $selected) return $optgroup_html; } -?> +?>
\ No newline at end of file diff --git a/libs/plugins/function.html_radios.php b/libs/plugins/function.html_radios.php index c7f72bf6..39c02330 100644 --- a/libs/plugins/function.html_radios.php +++ b/libs/plugins/function.html_radios.php @@ -1,45 +1,45 @@ <?php /** -* Smarty plugin -* -* @package Smarty -* @subpackage PluginsFunction -*/ + * Smarty plugin + * + * @package Smarty + * @subpackage PluginsFunction + */ /** -* Smarty {html_radios} function plugin -* -* File: function.html_radios.php<br> -* Type: function<br> -* Name: html_radios<br> -* Date: 24.Feb.2003<br> -* Purpose: Prints out a list of radio input types<br> -* Examples: -* <pre> -* {html_radios values=$ids output=$names} -* {html_radios values=$ids name='box' separator='<br>' output=$names} -* {html_radios values=$ids checked=$checked separator='<br>' output=$names} -* </pre> -* -* @link http://smarty.php.net/manual/en/language.function.html.radios.php {html_radios} - (Smarty online manual) -* @author Christopher Kvarme <christopher.kvarme@flashjab.com> -* @author credits to Monte Ohrt <monte at ohrt dot com> -* @version 1.0 -* @param array $params parameters -* Input:<br> -* - name (optional) - string default "radio" -* - values (required) - array -* - options (optional) - associative array -* - checked (optional) - array default not set -* - separator (optional) - ie <br> or -* - output (optional) - the output next to each radio button -* - assign (optional) - assign the output as an array to this variable -* @param object $smarty Smarty object -* @param object $template template object -* @return string -* @uses smarty_function_escape_special_chars() -*/ + * Smarty {html_radios} function plugin + * + * File: function.html_radios.php<br> + * Type: function<br> + * Name: html_radios<br> + * Date: 24.Feb.2003<br> + * Purpose: Prints out a list of radio input types<br> + * Examples: + * <pre> + * {html_radios values=$ids output=$names} + * {html_radios values=$ids name='box' separator='<br>' output=$names} + * {html_radios values=$ids checked=$checked separator='<br>' output=$names} + * </pre> + * + * @link http://smarty.php.net/manual/en/language.function.html.radios.php {html_radios} + * (Smarty online manual) + * @author Christopher Kvarme <christopher.kvarme@flashjab.com> + * @author credits to Monte Ohrt <monte at ohrt dot com> + * @version 1.0 + * @param array $params parameters + * Input:<br> + * - name (optional) - string default "radio" + * - values (required) - array + * - options (optional) - associative array + * - checked (optional) - array default not set + * - separator (optional) - ie <br> or + * - output (optional) - the output next to each radio button + * - assign (optional) - assign the output as an array to this variable + * @param object $smarty Smarty object + * @param object $template template object + * @return string + * @uses smarty_function_escape_special_chars() + */ function smarty_function_html_radios($params, $smarty, $template) { require_once(SMARTY_PLUGINS_DIR . 'shared.escape_special_chars.php'); @@ -153,4 +153,4 @@ function smarty_function_html_radios_output($name, $value, $output, $selected, $ return $_output; } -?> +?>
\ No newline at end of file diff --git a/libs/plugins/function.html_select_date.php b/libs/plugins/function.html_select_date.php index 7001f887..cd20d689 100644 --- a/libs/plugins/function.html_select_date.php +++ b/libs/plugins/function.html_select_date.php @@ -1,43 +1,43 @@ <?php /** -* Smarty plugin -* -* @package Smarty -* @subpackage PluginsFunction -*/ + * Smarty plugin + * + * @package Smarty + * @subpackage PluginsFunction + */ /** -* Smarty {html_select_date} plugin -* -* Type: function<br> -* Name: html_select_date<br> -* Purpose: Prints the dropdowns for date selection. -* -* ChangeLog:<br> -* - 1.0 initial release -* - 1.1 added support for +/- N syntax for begin -* and end year values. (Monte) -* - 1.2 added support for yyyy-mm-dd syntax for -* time value. (Jan Rosier) -* - 1.3 added support for choosing format for -* month values (Gary Loescher) -* - 1.3.1 added support for choosing format for -* day values (Marcus Bointon) -* - 1.3.2 support negative timestamps, force year -* dropdown to include given date unless explicitly set (Monte) -* - 1.3.4 fix behaviour of 0000-00-00 00:00:00 dates to match that -* of 0000-00-00 dates (cybot, boots) -* -* @link http://smarty.php.net/manual/en/language.function.html.select.date.php {html_select_date} - (Smarty online manual) -* @version 1.3.4 -* @author Andrei Zmievski -* @author Monte Ohrt <monte at ohrt dot com> -* @param array $params parameters -* @param object $smarty Smarty object -* @param object $template template object -* @return string -*/ + * Smarty {html_select_date} plugin + * + * Type: function<br> + * Name: html_select_date<br> + * Purpose: Prints the dropdowns for date selection. + * + * ChangeLog:<br> + * - 1.0 initial release + * - 1.1 added support for +/- N syntax for begin + * and end year values. (Monte) + * - 1.2 added support for yyyy-mm-dd syntax for + * time value. (Jan Rosier) + * - 1.3 added support for choosing format for + * month values (Gary Loescher) + * - 1.3.1 added support for choosing format for + * day values (Marcus Bointon) + * - 1.3.2 support negative timestamps, force year + * dropdown to include given date unless explicitly set (Monte) + * - 1.3.4 fix behaviour of 0000-00-00 00:00:00 dates to match that + * of 0000-00-00 dates (cybot, boots) + * + * @link http://smarty.php.net/manual/en/language.function.html.select.date.php {html_select_date} + * (Smarty online manual) + * @version 1.3.4 + * @author Andrei Zmievski + * @author Monte Ohrt <monte at ohrt dot com> + * @param array $params parameters + * @param object $smarty Smarty object + * @param object $template template object + * @return string + */ function smarty_function_html_select_date($params, $smarty, $template) { require_once(SMARTY_PLUGINS_DIR . 'shared.escape_special_chars.php'); @@ -329,5 +329,6 @@ function smarty_function_html_select_date($params, $smarty, $template) } return $html_result; -} -?> +} + +?>
\ No newline at end of file diff --git a/libs/plugins/function.html_select_time.php b/libs/plugins/function.html_select_time.php index 51d307ae..e9d95c2f 100644 --- a/libs/plugins/function.html_select_time.php +++ b/libs/plugins/function.html_select_time.php @@ -1,28 +1,28 @@ <?php /** -* Smarty plugin -* -* @package Smarty -* @subpackage PluginsFunction -*/ + * Smarty plugin + * + * @package Smarty + * @subpackage PluginsFunction + */ /** -* Smarty {html_select_time} function plugin -* -* Type: function<br> -* Name: html_select_time<br> -* Purpose: Prints the dropdowns for time selection -* -* @link http://smarty.php.net/manual/en/language.function.html.select.time.php {html_select_time} - (Smarty online manual) -* @author Roberto Berto <roberto@berto.net> -* @credits Monte Ohrt <monte AT ohrt DOT com> -* @param array $params parameters -* @param object $smarty Smarty object -* @param object $template template object -* @return string -* @uses smarty_make_timestamp() -*/ + * Smarty {html_select_time} function plugin + * + * Type: function<br> + * Name: html_select_time<br> + * Purpose: Prints the dropdowns for time selection + * + * @link http://smarty.php.net/manual/en/language.function.html.select.time.php {html_select_time} + * (Smarty online manual) + * @author Roberto Berto <roberto@berto.net> + * @credits Monte Ohrt <monte AT ohrt DOT com> + * @param array $params parameters + * @param object $smarty Smarty object + * @param object $template template object + * @return string + * @uses smarty_make_timestamp() + */ function smarty_function_html_select_time($params, $smarty, $template) { require_once(SMARTY_PLUGINS_DIR . 'shared.make_timestamp.php'); @@ -194,4 +194,4 @@ function smarty_function_html_select_time($params, $smarty, $template) return $html_result; } -?> +?>
\ No newline at end of file diff --git a/libs/plugins/function.html_table.php b/libs/plugins/function.html_table.php index 198b03ca..83e80300 100644 --- a/libs/plugins/function.html_table.php +++ b/libs/plugins/function.html_table.php @@ -1,53 +1,53 @@ <?php /** -* Smarty plugin -* -* @package Smarty -* @subpackage PluginsFunction -*/ + * Smarty plugin + * + * @package Smarty + * @subpackage PluginsFunction + */ /** -* Smarty {html_table} function plugin -* -* Type: function<br> -* Name: html_table<br> -* Date: Feb 17, 2003<br> -* Purpose: make an html table from an array of data<br> -* -* -* Examples: -* <pre> -* {table loop=$data} -* {table loop=$data cols=4 tr_attr='"bgcolor=red"'} -* {table loop=$data cols="first,second,third" tr_attr=$colors} -* </pre> -* -* @author Monte Ohrt <monte at ohrt dot com> -* @author credit to Messju Mohr <messju at lammfellpuschen dot de> -* @author credit to boots <boots dot smarty at yahoo dot com> -* @version 1.1 -* @link http://smarty.php.net/manual/en/language.function.html.table.php {html_table} - (Smarty online manual) -* @param array $params parameters -* Input:<br> -* - loop = array to loop through -* - cols = number of columns, comma separated list of column names -* or array of column names -* - rows = number of rows -* - table_attr = table attributes -* - th_attr = table heading attributes (arrays are cycled) -* - tr_attr = table row attributes (arrays are cycled) -* - td_attr = table cell attributes (arrays are cycled) -* - trailpad = value to pad trailing cells with -* - caption = text for caption element -* - vdir = vertical direction (default: "down", means top-to-bottom) -* - hdir = horizontal direction (default: "right", means left-to-right) -* - inner = inner loop (default "cols": print $loop line by line, -* $loop will be printed column by column otherwise) -* @param object $smarty Smarty object -* @param object $template template object -* @return string -*/ + * Smarty {html_table} function plugin + * + * Type: function<br> + * Name: html_table<br> + * Date: Feb 17, 2003<br> + * Purpose: make an html table from an array of data<br> + * + * + * Examples: + * <pre> + * {table loop=$data} + * {table loop=$data cols=4 tr_attr='"bgcolor=red"'} + * {table loop=$data cols="first,second,third" tr_attr=$colors} + * </pre> + * + * @author Monte Ohrt <monte at ohrt dot com> + * @author credit to Messju Mohr <messju at lammfellpuschen dot de> + * @author credit to boots <boots dot smarty at yahoo dot com> + * @version 1.1 + * @link http://smarty.php.net/manual/en/language.function.html.table.php {html_table} + * (Smarty online manual) + * @param array $params parameters + * Input:<br> + * - loop = array to loop through + * - cols = number of columns, comma separated list of column names + * or array of column names + * - rows = number of rows + * - table_attr = table attributes + * - th_attr = table heading attributes (arrays are cycled) + * - tr_attr = table row attributes (arrays are cycled) + * - td_attr = table cell attributes (arrays are cycled) + * - trailpad = value to pad trailing cells with + * - caption = text for caption element + * - vdir = vertical direction (default: "down", means top-to-bottom) + * - hdir = horizontal direction (default: "right", means left-to-right) + * - inner = inner loop (default "cols": print $loop line by line, + * $loop will be printed column by column otherwise) + * @param object $smarty Smarty object + * @param object $template template object + * @return string + */ function smarty_function_html_table($params, $smarty, $template) { $table_attr = 'border="1"'; @@ -172,5 +172,6 @@ function smarty_function_html_table_cycle($name, $var, $no) } return ($ret) ? ' ' . $ret : ''; -} -?> +} + +?>
\ No newline at end of file diff --git a/libs/plugins/function.mailto.php b/libs/plugins/function.mailto.php index 29a87c69..f75dc71b 100644 --- a/libs/plugins/function.mailto.php +++ b/libs/plugins/function.mailto.php @@ -1,54 +1,54 @@ <?php /** -* Smarty plugin -* -* @package Smarty -* @subpackage PluginsFunction -*/ + * Smarty plugin + * + * @package Smarty + * @subpackage PluginsFunction + */ /** -* Smarty {mailto} function plugin -* -* Type: function<br> -* Name: mailto<br> -* Date: May 21, 2002 -* Purpose: automate mailto address link creation, and optionally -* encode them.<br> -* -* Examples: -* <pre> -* {mailto address="me@domain.com"} -* {mailto address="me@domain.com" encode="javascript"} -* {mailto address="me@domain.com" encode="hex"} -* {mailto address="me@domain.com" subject="Hello to you!"} -* {mailto address="me@domain.com" cc="you@domain.com,they@domain.com"} -* {mailto address="me@domain.com" extra='class="mailto"'} -* </pre> -* -* @link http://smarty.php.net/manual/en/language.function.mailto.php {mailto} - (Smarty online manual) -* @version 1.2 -* @author Monte Ohrt <monte at ohrt dot com> -* @author credits to Jason Sweat (added cc, bcc and subject functionality) -* @param array $params parameters -* Input:<br> -* - address = e-mail address -* - text = (optional) text to display, default is address -* - encode = (optional) can be one of: -* * none : no encoding (default) -* * javascript : encode with javascript -* * javascript_charcode : encode with javascript charcode -* * hex : encode with hexidecimal (no javascript) -* - cc = (optional) address(es) to carbon copy -* - bcc = (optional) address(es) to blind carbon copy -* - subject = (optional) e-mail subject -* - newsgroups = (optional) newsgroup(s) to post to -* - followupto = (optional) address(es) to follow up to -* - extra = (optional) extra tags for the href link -* @param object $smarty Smarty object -* @param object $template template object -* @return string -*/ + * Smarty {mailto} function plugin + * + * Type: function<br> + * Name: mailto<br> + * Date: May 21, 2002 + * Purpose: automate mailto address link creation, and optionally + * encode them.<br> + * + * Examples: + * <pre> + * {mailto address="me@domain.com"} + * {mailto address="me@domain.com" encode="javascript"} + * {mailto address="me@domain.com" encode="hex"} + * {mailto address="me@domain.com" subject="Hello to you!"} + * {mailto address="me@domain.com" cc="you@domain.com,they@domain.com"} + * {mailto address="me@domain.com" extra='class="mailto"'} + * </pre> + * + * @link http://smarty.php.net/manual/en/language.function.mailto.php {mailto} + * (Smarty online manual) + * @version 1.2 + * @author Monte Ohrt <monte at ohrt dot com> + * @author credits to Jason Sweat (added cc, bcc and subject functionality) + * @param array $params parameters + * Input:<br> + * - address = e-mail address + * - text = (optional) text to display, default is address + * - encode = (optional) can be one of: + * * none : no encoding (default) + * * javascript : encode with javascript + * * javascript_charcode : encode with javascript charcode + * * hex : encode with hexidecimal (no javascript) + * - cc = (optional) address(es) to carbon copy + * - bcc = (optional) address(es) to blind carbon copy + * - subject = (optional) e-mail subject + * - newsgroups = (optional) newsgroup(s) to post to + * - followupto = (optional) address(es) to follow up to + * - extra = (optional) extra tags for the href link + * @param object $smarty Smarty object + * @param object $template template object + * @return string + */ function smarty_function_mailto($params, $smarty, $template) { $extra = ''; @@ -154,4 +154,4 @@ function smarty_function_mailto($params, $smarty, $template) } } -?> +?>
\ No newline at end of file diff --git a/libs/plugins/function.math.php b/libs/plugins/function.math.php index 257d2fee..edeef5af 100644 --- a/libs/plugins/function.math.php +++ b/libs/plugins/function.math.php @@ -7,7 +7,6 @@ * @subpackage PluginsFunction */ - /** * Smarty {math} function plugin * @@ -81,4 +80,5 @@ function smarty_function_math($params, $smarty, $template) } } } + ?>
\ No newline at end of file diff --git a/libs/plugins/function.popup.php b/libs/plugins/function.popup.php index e683556a..c646181a 100644 --- a/libs/plugins/function.popup.php +++ b/libs/plugins/function.popup.php @@ -1,11 +1,11 @@ <?php /** * Smarty plugin + * * @package Smarty * @subpackage PluginsFunction */ - /** * Smarty {popup} function plugin * @@ -115,4 +115,5 @@ function smarty_function_popup($params, $smarty, $template) return $retval; } -?> + +?>
\ No newline at end of file diff --git a/libs/plugins/function.popup_init.php b/libs/plugins/function.popup_init.php index dc5bbd7a..ba1f9a65 100644 --- a/libs/plugins/function.popup_init.php +++ b/libs/plugins/function.popup_init.php @@ -1,25 +1,26 @@ <?php /** - * Smarty plugin - * @package Smarty - * @subpackage PluginsFunction - */ - + * Smarty plugin + * + * @package Smarty + * @subpackage PluginsFunction + */ /** - * Smarty {popup_init} function plugin - * - * Type: function<br> - * Name: popup_init<br> - * Purpose: initialize overlib - * @link http://smarty.php.net/manual/en/language.function.popup.init.php {popup_init} - * (Smarty online manual) - * @author Monte Ohrt <monte at ohrt dot com> - * @param array $params parameters - * @param object $smarty Smarty object - * @param object $template template object - * @return string - */ + * Smarty {popup_init} function plugin + * + * Type: function<br> + * Name: popup_init<br> + * Purpose: initialize overlib + * @link http://smarty.php.net/manual/en/language.function.popup.init.php {popup_init} + * (Smarty online manual) + * @author Monte Ohrt <monte at ohrt dot com> + * @param array $params parameters + * @param object $smarty Smarty object + * @param object $template template object + * @return string + */ + function smarty_function_popup_init($params, $smarty, $template) { $zindex = 1000; @@ -35,4 +36,5 @@ function smarty_function_popup_init($params, $smarty, $template) trigger_error("popup_init: missing src parameter",E_USER_WARNING); } } + ?>
\ No newline at end of file diff --git a/libs/plugins/modifier.date_format.php b/libs/plugins/modifier.date_format.php index 950a1958..3656c1c8 100644 --- a/libs/plugins/modifier.date_format.php +++ b/libs/plugins/modifier.date_format.php @@ -1,30 +1,30 @@ <?php /** -* Smarty plugin -* -* @package Smarty -* @subpackage PluginsModifier -*/ + * Smarty plugin + * + * @package Smarty + * @subpackage PluginsModifier + */ /** -* Smarty date_format modifier plugin -* -* Type: modifier<br> -* Name: date_format<br> -* Purpose: format datestamps via strftime<br> -* Input:<br> -* - string: input date string -* - format: strftime format for output -* - default_date: default date if $string is empty -* -* @link http://smarty.php.net/manual/en/language.modifier.date.format.php date_format (Smarty online manual) -* @author Monte Ohrt <monte at ohrt dot com> -* @param string $ -* @param string $ -* @param string $ -* @return string |void -* @uses smarty_make_timestamp() -*/ + * Smarty date_format modifier plugin + * + * Type: modifier<br> + * Name: date_format<br> + * Purpose: format datestamps via strftime<br> + * Input:<br> + * - string: input date string + * - format: strftime format for output + * - default_date: default date if $string is empty + * + * @link http://smarty.php.net/manual/en/language.modifier.date.format.php date_format (Smarty online manual) + * @author Monte Ohrt <monte at ohrt dot com> + * @param string $ + * @param string $ + * @param string $ + * @return string |void + * @uses smarty_make_timestamp() + */ function smarty_modifier_date_format($string, $format = SMARTY_RESOURCE_DATE_FORMAT, $default_date = '',$formatter='auto') { /** @@ -58,4 +58,4 @@ function smarty_modifier_date_format($string, $format = SMARTY_RESOURCE_DATE_FOR } } -?> +?>
\ No newline at end of file diff --git a/libs/plugins/modifier.debug_print_var.php b/libs/plugins/modifier.debug_print_var.php index f0f83d27..013337ae 100644 --- a/libs/plugins/modifier.debug_print_var.php +++ b/libs/plugins/modifier.debug_print_var.php @@ -1,25 +1,25 @@ <?php /** -* Smarty plugin -* -* @package Smarty -* @subpackage Debug -*/ + * Smarty plugin + * + * @package Smarty + * @subpackage Debug + */ /** -* Smarty debug_print_var modifier plugin -* -* Type: modifier<br> -* Name: debug_print_var<br> -* Purpose: formats variable contents for display in the console -* -* @link http://smarty.php.net/manual/en/language.modifier.debug.print.var.php debug_print_var (Smarty online manual) -* @author Monte Ohrt <monte at ohrt dot com> -* @param array $ |object -* @param integer $ -* @param integer $ -* @return string -*/ + * Smarty debug_print_var modifier plugin + * + * Type: modifier<br> + * Name: debug_print_var<br> + * Purpose: formats variable contents for display in the console + * + * @link http://smarty.php.net/manual/en/language.modifier.debug.print.var.php debug_print_var (Smarty online manual) + * @author Monte Ohrt <monte at ohrt dot com> + * @param array $ |object + * @param integer $ + * @param integer $ + * @return string + */ function smarty_modifier_debug_print_var ($var, $depth = 0, $length = 40) { $_replace = array("\n" => '<i>\n</i>', @@ -84,4 +84,4 @@ function smarty_modifier_debug_print_var ($var, $depth = 0, $length = 40) return $results; } -?> +?>
\ No newline at end of file diff --git a/libs/plugins/modifier.escape.php b/libs/plugins/modifier.escape.php index 46368867..dae59268 100644 --- a/libs/plugins/modifier.escape.php +++ b/libs/plugins/modifier.escape.php @@ -1,12 +1,11 @@ <?php - /** * Smarty plugin * * @package Smarty * @subpackage PluginsModifier */ - + /** * Smarty escape modifier plugin * diff --git a/libs/plugins/modifier.regex_replace.php b/libs/plugins/modifier.regex_replace.php index 16f4c48e..9f148800 100644 --- a/libs/plugins/modifier.regex_replace.php +++ b/libs/plugins/modifier.regex_replace.php @@ -1,10 +1,10 @@ <?php /** * Smarty plugin + * * @package Smarty * @subpackage PluginsModifier -*/ - + */ /** * Smarty regex_replace modifier plugin @@ -42,4 +42,5 @@ function _smarty_regex_replace_check($search) } return $search; } + ?>
\ No newline at end of file diff --git a/libs/plugins/modifier.replace.php b/libs/plugins/modifier.replace.php index 80f67e29..98195ffb 100644 --- a/libs/plugins/modifier.replace.php +++ b/libs/plugins/modifier.replace.php @@ -1,7 +1,6 @@ <?php /** * Smarty plugin - * * @package Smarty * @subpackage PluginsModifier */ diff --git a/libs/plugins/modifier.spacify.php b/libs/plugins/modifier.spacify.php index 790e373b..f14e026b 100644 --- a/libs/plugins/modifier.spacify.php +++ b/libs/plugins/modifier.spacify.php @@ -1,7 +1,6 @@ <?php /** * Smarty plugin - * * @package Smarty * @subpackage PluginsModifier */ diff --git a/libs/plugins/modifier.truncate.php b/libs/plugins/modifier.truncate.php index 308fd48c..0e9d4b9f 100644 --- a/libs/plugins/modifier.truncate.php +++ b/libs/plugins/modifier.truncate.php @@ -1,11 +1,11 @@ <?php /** * Smarty plugin - * + * * @package Smarty * @subpackage PluginsModifier */ - + /** * Smarty truncate modifier plugin * diff --git a/libs/plugins/modifiercompiler.cat.php b/libs/plugins/modifiercompiler.cat.php index a388c6f8..37019d72 100644 --- a/libs/plugins/modifiercompiler.cat.php +++ b/libs/plugins/modifiercompiler.cat.php @@ -1,11 +1,11 @@ <?php
/**
* Smarty plugin
+ *
* @package Smarty
* @subpackage PluginsModifierCompiler
*/
-
/**
* Smarty cat modifier plugin
*
@@ -23,7 +23,7 @@ */
function smarty_modifiercompiler_cat($params, $compiler)
{
- return '('.implode(').(', $params).')';
+ return '('.implode(').(', $params).')';
}
?>
\ No newline at end of file diff --git a/libs/plugins/modifiercompiler.count_characters.php b/libs/plugins/modifiercompiler.count_characters.php index 9a620c49..6f00e6aa 100644 --- a/libs/plugins/modifiercompiler.count_characters.php +++ b/libs/plugins/modifiercompiler.count_characters.php @@ -1,7 +1,7 @@ <?php
/**
* Smarty plugin
- *
+ *
* @package Smarty
* @subpackage PluginsModifierCompiler
*/
@@ -34,5 +34,6 @@ function smarty_modifiercompiler_count_characters($params, $compiler) }
return 'preg_match_all(\'/[^\s]/\',' . $params[0] . ', $tmp)';
}
-}
+}
+
?>
\ No newline at end of file diff --git a/libs/plugins/modifiercompiler.count_paragraphs.php b/libs/plugins/modifiercompiler.count_paragraphs.php index 412bbd7d..09973ef3 100644 --- a/libs/plugins/modifiercompiler.count_paragraphs.php +++ b/libs/plugins/modifiercompiler.count_paragraphs.php @@ -1,11 +1,11 @@ <?php
/**
* Smarty plugin
+ *
* @package Smarty
* @subpackage PluginsModifierCompiler
*/
-
/**
* Smarty count_paragraphs modifier plugin
*
@@ -23,4 +23,5 @@ function smarty_modifiercompiler_count_paragraphs($params, $compiler) // count \r or \n characters
return '(preg_match_all(\'#[\r\n]+#\', ' . $params[0] . ', $tmp)+1)';
}
+
?>
\ No newline at end of file diff --git a/libs/plugins/modifiercompiler.count_sentences.php b/libs/plugins/modifiercompiler.count_sentences.php index c410868d..cde5c467 100644 --- a/libs/plugins/modifiercompiler.count_sentences.php +++ b/libs/plugins/modifiercompiler.count_sentences.php @@ -1,11 +1,11 @@ <?php
/**
* Smarty plugin
+ *
* @package Smarty
* @subpackage PluginsModifierCompiler
*/
-
/**
* Smarty count_sentences modifier plugin
*
diff --git a/libs/plugins/modifiercompiler.count_words.php b/libs/plugins/modifiercompiler.count_words.php index cf40e9d3..7eaaf749 100644 --- a/libs/plugins/modifiercompiler.count_words.php +++ b/libs/plugins/modifiercompiler.count_words.php @@ -17,7 +17,7 @@ * @author Uwe Tews
* @param array $params parameters
* @return string with compiled code
- */
+*/
function smarty_modifiercompiler_count_words($params, $compiler)
{
// mb_ functions available?
diff --git a/libs/plugins/modifiercompiler.default.php b/libs/plugins/modifiercompiler.default.php index 444b285b..addd4aa0 100644 --- a/libs/plugins/modifiercompiler.default.php +++ b/libs/plugins/modifiercompiler.default.php @@ -1,7 +1,7 @@ <?php
/**
* Smarty plugin
- *
+ *
* @package Smarty
* @subpackage PluginsModifierCompiler
*/
diff --git a/libs/plugins/modifiercompiler.indent.php b/libs/plugins/modifiercompiler.indent.php index cc690725..e62d56ca 100644 --- a/libs/plugins/modifiercompiler.indent.php +++ b/libs/plugins/modifiercompiler.indent.php @@ -5,7 +5,6 @@ * @subpackage PluginsModifierCompiler
*/
-
/**
* Smarty indent modifier plugin
*
@@ -18,6 +17,7 @@ * @param array $params parameters
* @return string with compiled code
*/
+
function smarty_modifiercompiler_indent($params, $compiler)
{
if (!isset($params[1])) {
diff --git a/libs/plugins/modifiercompiler.lower.php b/libs/plugins/modifiercompiler.lower.php index 835c8a40..2018bbf4 100644 --- a/libs/plugins/modifiercompiler.lower.php +++ b/libs/plugins/modifiercompiler.lower.php @@ -1,24 +1,24 @@ <?php
/**
-* Smarty plugin
-*
-* @package Smarty
-* @subpackage PluginsModifierCompiler
-*/
+ * Smarty plugin
+ * @package Smarty
+ * @subpackage PluginsModifierCompiler
+ */
/**
-* Smarty lower modifier plugin
-*
-* Type: modifier<br>
-* Name: lower<br>
-* Purpose: convert string to lowercase
-*
-* @link http://smarty.php.net/manual/en/language.modifier.lower.php lower (Smarty online manual)
-* @author Monte Ohrt <monte at ohrt dot com>
+ * Smarty lower modifier plugin
+ *
+ * Type: modifier<br>
+ * Name: lower<br>
+ * Purpose: convert string to lowercase
+ *
+ * @link http://smarty.php.net/manual/en/language.modifier.lower.php lower (Smarty online manual)
+ * @author Monte Ohrt <monte at ohrt dot com>
* @author Uwe Tews
* @param array $params parameters
* @return string with compiled code
-*/
+ */
+
function smarty_modifiercompiler_lower($params, $compiler)
{
if (function_exists('mb_strtolower')) {
diff --git a/libs/plugins/modifiercompiler.noprint.php b/libs/plugins/modifiercompiler.noprint.php index 15c9999f..cd2a663e 100644 --- a/libs/plugins/modifiercompiler.noprint.php +++ b/libs/plugins/modifiercompiler.noprint.php @@ -1,11 +1,11 @@ <?php
/**
* Smarty plugin
+ *
* @package Smarty
* @subpackage PluginsModifierCompiler
*/
-
/**
* Smarty noprint modifier plugin
*
diff --git a/libs/plugins/modifiercompiler.string_format.php b/libs/plugins/modifiercompiler.string_format.php index dd414ba1..fd9fd876 100644 --- a/libs/plugins/modifiercompiler.string_format.php +++ b/libs/plugins/modifiercompiler.string_format.php @@ -1,26 +1,26 @@ <?php
/**
-* Smarty plugin
-*
-* @package Smarty
-* @subpackage PluginsModifierCompiler
-*/
+ * Smarty plugin
+ *
+ * @package Smarty
+ * @subpackage PluginsModifierCompiler
+ */
/**
-* Smarty string_format modifier plugin
-*
-* Type: modifier<br>
-* Name: string_format<br>
-* Purpose: format strings via sprintf
-*
-* @link http://smarty.php.net/manual/en/language.modifier.string.format.php string_format (Smarty online manual)
+ * Smarty string_format modifier plugin
+ *
+ * Type: modifier<br>
+ * Name: string_format<br>
+ * Purpose: format strings via sprintf
+ *
+ * @link http://smarty.php.net/manual/en/language.modifier.string.format.php string_format (Smarty online manual)
* @author Uwe Tews
* @param array $params parameters
* @return string with compiled code
-*/
- function smarty_modifiercompiler_string_format($params, $compiler)
- {
- return 'sprintf(' . $params[1] . ',' . $params[0] . ')';
- }
+ */
+function smarty_modifiercompiler_string_format($params, $compiler)
+{
+ return 'sprintf(' . $params[1] . ',' . $params[0] . ')';
+}
?>
\ No newline at end of file diff --git a/libs/plugins/modifiercompiler.strip.php b/libs/plugins/modifiercompiler.strip.php index 25d66f01..ab5b7688 100644 --- a/libs/plugins/modifiercompiler.strip.php +++ b/libs/plugins/modifiercompiler.strip.php @@ -1,7 +1,7 @@ <?php
/**
* Smarty plugin
- *
+ *
* @package Smarty
* @subpackage PluginsModifierCompiler
*/
@@ -21,6 +21,7 @@ * @param array $params parameters
* @return string with compiled code
*/
+
function smarty_modifiercompiler_strip($params, $compiler)
{
if (!isset($params[1])) {
diff --git a/libs/plugins/modifiercompiler.strip_tags.php b/libs/plugins/modifiercompiler.strip_tags.php index 97be3b8e..5e479b28 100644 --- a/libs/plugins/modifiercompiler.strip_tags.php +++ b/libs/plugins/modifiercompiler.strip_tags.php @@ -1,7 +1,7 @@ <?php
/**
* Smarty plugin
- *
+ *
* @package Smarty
* @subpackage PluginsModifierCompiler
*/
@@ -18,6 +18,7 @@ * @param array $params parameters
* @return string with compiled code
*/
+
function smarty_modifiercompiler_strip_tags($params, $compiler)
{
if (!isset($params[1])) {
diff --git a/libs/plugins/modifiercompiler.upper.php b/libs/plugins/modifiercompiler.upper.php index 6e1f54ab..def73043 100644 --- a/libs/plugins/modifiercompiler.upper.php +++ b/libs/plugins/modifiercompiler.upper.php @@ -1,7 +1,7 @@ <?php
/**
* Smarty plugin
- *
+ *
* @package Smarty
* @subpackage PluginsModifierCompiler
*/
diff --git a/libs/plugins/modifiercompiler.wordwrap.php b/libs/plugins/modifiercompiler.wordwrap.php index 37ca2709..5b91f64c 100644 --- a/libs/plugins/modifiercompiler.wordwrap.php +++ b/libs/plugins/modifiercompiler.wordwrap.php @@ -1,7 +1,7 @@ <?php
/**
* Smarty plugin
- *
+ *
* @package Smarty
* @subpackage PluginsModifierCompiler
*/
diff --git a/libs/plugins/outputfilter.trimwhitespace.php b/libs/plugins/outputfilter.trimwhitespace.php index ce5fde98..20e9bb60 100644 --- a/libs/plugins/outputfilter.trimwhitespace.php +++ b/libs/plugins/outputfilter.trimwhitespace.php @@ -1,6 +1,7 @@ <?php /** * Smarty plugin + * * @package Smarty * @subpackage PluginsFilter */ @@ -73,4 +74,4 @@ function smarty_outputfilter_trimwhitespace_replace($search_str, $replace, &$sub } -?> +?>
\ No newline at end of file diff --git a/libs/plugins/shared.escape_special_chars.php b/libs/plugins/shared.escape_special_chars.php index 5bd21ef8..e36b2c89 100644 --- a/libs/plugins/shared.escape_special_chars.php +++ b/libs/plugins/shared.escape_special_chars.php @@ -1,11 +1,11 @@ <?php /** * Smarty shared plugin + * * @package Smarty * @subpackage PluginsShared */ - /** * escape_special_chars common function * @@ -25,4 +25,5 @@ function smarty_function_escape_special_chars($string) } return $string; } + ?>
\ No newline at end of file diff --git a/libs/plugins/shared.make_timestamp.php b/libs/plugins/shared.make_timestamp.php index dc2514b1..832488ba 100644 --- a/libs/plugins/shared.make_timestamp.php +++ b/libs/plugins/shared.make_timestamp.php @@ -1,11 +1,11 @@ <?php /** * Smarty shared plugin + * * @package Smarty * @subpackage PluginsShared */ - /** * Function: smarty_make_timestamp<br> * Purpose: used by other smarty functions to make a timestamp @@ -14,6 +14,7 @@ * @param string $string * @return string */ + function smarty_make_timestamp($string) { if(empty($string)) { @@ -38,4 +39,5 @@ function smarty_make_timestamp($string) return $time; } } + ?>
\ No newline at end of file diff --git a/libs/plugins/variablefilter.htmlspecialchars.php b/libs/plugins/variablefilter.htmlspecialchars.php index 5f11b734..4d3550c0 100644 --- a/libs/plugins/variablefilter.htmlspecialchars.php +++ b/libs/plugins/variablefilter.htmlspecialchars.php @@ -1,18 +1,19 @@ <?php /** -* Smarty plugin -* -* @package Smarty -* @subpackage PluginsFilter -*/ + * Smarty plugin + * + * @package Smarty + * @subpackage PluginsFilter + */ /** -* Smarty htmlspecialchars variablefilter plugin -* -* @param string $source input string -* @param object $ &$smarty Smarty object -* @return string filtered output -*/ + * Smarty htmlspecialchars variablefilter plugin + * + * @param string $source input string + * @param object $ &$smarty Smarty object + * @return string filtered output + */ + function smarty_variablefilter_htmlspecialchars($source, $smarty) { return htmlspecialchars($source, ENT_QUOTES); diff --git a/libs/sysplugins/smarty_internal_compile_append.php b/libs/sysplugins/smarty_internal_compile_append.php index 5f207626..c9a05c33 100644 --- a/libs/sysplugins/smarty_internal_compile_append.php +++ b/libs/sysplugins/smarty_internal_compile_append.php @@ -1,17 +1,18 @@ <?php /** -* Smarty Internal Plugin Compile Append -* -* Compiles the {append} tag -* -* @package Smarty -* @subpackage Compiler -* @author Uwe Tews -*/ + * Smarty Internal Plugin Compile Append + * + * Compiles the {append} tag + * + * @package Smarty + * @subpackage Compiler + * @author Uwe Tews + */ + /** -* Smarty Internal Plugin Compile Append Class -*/ + * Smarty Internal Plugin Compile Append Class + */ class Smarty_Internal_Compile_Append extends Smarty_Internal_CompileBase { /** * Compiles code for the {append} tag diff --git a/libs/sysplugins/smarty_internal_compile_assign.php b/libs/sysplugins/smarty_internal_compile_assign.php index 4f3159fa..bdbefae3 100644 --- a/libs/sysplugins/smarty_internal_compile_assign.php +++ b/libs/sysplugins/smarty_internal_compile_assign.php @@ -9,6 +9,7 @@ * @subpackage Compiler * @author Uwe Tews */ + /** * Smarty Internal Plugin Compile Assign Class */ diff --git a/libs/sysplugins/smarty_internal_compile_block.php b/libs/sysplugins/smarty_internal_compile_block.php index 79ceeb7f..9f648cde 100644 --- a/libs/sysplugins/smarty_internal_compile_block.php +++ b/libs/sysplugins/smarty_internal_compile_block.php @@ -8,6 +8,7 @@ * @subpackage Compiler * @author Uwe Tews */ + /** * Smarty Internal Plugin Compile Block Class */ diff --git a/libs/sysplugins/smarty_internal_compile_call.php b/libs/sysplugins/smarty_internal_compile_call.php index 0f7e5214..e63bd1c8 100644 --- a/libs/sysplugins/smarty_internal_compile_call.php +++ b/libs/sysplugins/smarty_internal_compile_call.php @@ -9,6 +9,7 @@ * @subpackage Compiler * @author Uwe Tews */ + /** * Smarty Internal Plugin Compile Function_Call Class */ @@ -71,7 +72,7 @@ class Smarty_Internal_Compile_Call extends Smarty_Internal_CompileBase { } } $_params = 'array(' . implode(",", $_paramsArray) . ')'; - $_hash = str_replace('-','_',$compiler->template->properties['nocache_hash']); + $_hash = str_replace('-','_',$compiler->template->properties['nocache_hash']); // was there an assign attribute if (isset($_assign)) { if ($compiler->template->caching) { diff --git a/libs/sysplugins/smarty_internal_compile_capture.php b/libs/sysplugins/smarty_internal_compile_capture.php index 752cb3ae..96589cdd 100644 --- a/libs/sysplugins/smarty_internal_compile_capture.php +++ b/libs/sysplugins/smarty_internal_compile_capture.php @@ -1,24 +1,25 @@ <?php /** -* Smarty Internal Plugin Compile Capture -* -* Compiles the {capture} tag -* -* @package Smarty -* @subpackage Compiler -* @author Uwe Tews -*/ + * Smarty Internal Plugin Compile Capture + * + * Compiles the {capture} tag + * + * @package Smarty + * @subpackage Compiler + * @author Uwe Tews + */ + /** -* Smarty Internal Plugin Compile Capture Class -*/ + * Smarty Internal Plugin Compile Capture Class + */ class Smarty_Internal_Compile_Capture extends Smarty_Internal_CompileBase { /** - * Compiles code for the {capture} tag - * - * @param array $args array with attributes from parser - * @param object $compiler compiler object - * @return string compiled code - */ + * Compiles code for the {capture} tag + * + * @param array $args array with attributes from parser + * @param object $compiler compiler object + * @return string compiled code + */ public function compile($args, $compiler) { $this->compiler = $compiler; @@ -39,16 +40,16 @@ class Smarty_Internal_Compile_Capture extends Smarty_Internal_CompileBase { } /** -* Smarty Internal Plugin Compile Captureclose Class -*/ + * Smarty Internal Plugin Compile Captureclose Class + */ class Smarty_Internal_Compile_CaptureClose extends Smarty_Internal_CompileBase { /** - * Compiles code for the {/capture} tag - * - * @param array $args array with attributes from parser - * @param object $compiler compiler object - * @return string compiled code - */ + * Compiles code for the {/capture} tag + * + * @param array $args array with attributes from parser + * @param object $compiler compiler object + * @return string compiled code + */ public function compile($args, $compiler) { $this->compiler = $compiler; @@ -69,4 +70,4 @@ class Smarty_Internal_Compile_CaptureClose extends Smarty_Internal_CompileBase { } } -?> +?>
\ No newline at end of file diff --git a/libs/sysplugins/smarty_internal_compile_config_load.php b/libs/sysplugins/smarty_internal_compile_config_load.php index 199e9c4e..bb0103ed 100644 --- a/libs/sysplugins/smarty_internal_compile_config_load.php +++ b/libs/sysplugins/smarty_internal_compile_config_load.php @@ -9,6 +9,7 @@ * @subpackage Compiler * @author Uwe Tews */ + /** * Smarty Internal Plugin Compile Config Load Class */ diff --git a/libs/sysplugins/smarty_internal_compile_debug.php b/libs/sysplugins/smarty_internal_compile_debug.php index 8ff9671a..d6d8905f 100644 --- a/libs/sysplugins/smarty_internal_compile_debug.php +++ b/libs/sysplugins/smarty_internal_compile_debug.php @@ -1,24 +1,25 @@ <?php /** -* Smarty Internal Plugin Compile Debug -* -* Compiles the {debug} tag -* It opens a window the the Smarty Debugging Console -* @package Smarty -* @subpackage Compiler -* @author Uwe Tews -*/ + * Smarty Internal Plugin Compile Debug + * + * Compiles the {debug} tag + * It opens a window the the Smarty Debugging Console + * @package Smarty + * @subpackage Compiler + * @author Uwe Tews + */ + /** -* Smarty Internal Plugin Compile Debug Class -*/ + * Smarty Internal Plugin Compile Debug Class + */ class Smarty_Internal_Compile_Debug extends Smarty_Internal_CompileBase { /** - * Compiles code for the {debug} tag - * - * @param array $args array with attributes from parser - * @param object $compiler compiler object - * @return string compiled code - */ + * Compiles code for the {debug} tag + * + * @param array $args array with attributes from parser + * @param object $compiler compiler object + * @return string compiled code + */ public function compile($args, $compiler) { $this->compiler = $compiler; @@ -31,4 +32,4 @@ class Smarty_Internal_Compile_Debug extends Smarty_Internal_CompileBase { } } -?> +?>
\ No newline at end of file diff --git a/libs/sysplugins/smarty_internal_compile_eval.php b/libs/sysplugins/smarty_internal_compile_eval.php index 6f17de77..747f8e73 100644 --- a/libs/sysplugins/smarty_internal_compile_eval.php +++ b/libs/sysplugins/smarty_internal_compile_eval.php @@ -1,24 +1,25 @@ <?php /** -* Smarty Internal Plugin Compile Eval -* -* Compiles the {eval} tag -* @package Smarty -* @subpackage Compiler -* @author Uwe Tews -*/ + * Smarty Internal Plugin Compile Eval + * + * Compiles the {eval} tag + * @package Smarty + * @subpackage Compiler + * @author Uwe Tews + */ + /** -* Smarty Internal Plugin Compile Eval Class -*/ + * Smarty Internal Plugin Compile Eval Class + */ class Smarty_Internal_Compile_Eval extends Smarty_Internal_CompileBase { /** - * Compiles code for the {eval} tag - * - * @param array $args array with attributes from parser - * @param object $compiler compiler object - * @return string compiled code - */ + * Compiles code for the {eval} tag + * + * @param array $args array with attributes from parser + * @param object $compiler compiler object + * @return string compiled code + */ public function compile($args, $compiler) { $this->compiler = $compiler; @@ -43,4 +44,4 @@ class Smarty_Internal_Compile_Eval extends Smarty_Internal_CompileBase { } } -?> +?>
\ No newline at end of file diff --git a/libs/sysplugins/smarty_internal_compile_extends.php b/libs/sysplugins/smarty_internal_compile_extends.php index f07e80d9..4075a962 100644 --- a/libs/sysplugins/smarty_internal_compile_extends.php +++ b/libs/sysplugins/smarty_internal_compile_extends.php @@ -9,6 +9,7 @@ * @subpackage Compiler * @author Uwe Tews */ + /** * Smarty Internal Plugin Compile extend Class */ diff --git a/libs/sysplugins/smarty_internal_compile_for.php b/libs/sysplugins/smarty_internal_compile_for.php index a848a6f4..77f196cc 100644 --- a/libs/sysplugins/smarty_internal_compile_for.php +++ b/libs/sysplugins/smarty_internal_compile_for.php @@ -8,6 +8,7 @@ * @subpackage Compiler * @author Uwe Tews */ + /** * Smarty Internal Plugin Compile For Class */ diff --git a/libs/sysplugins/smarty_internal_compile_foreach.php b/libs/sysplugins/smarty_internal_compile_foreach.php index 54440319..52b78c33 100644 --- a/libs/sysplugins/smarty_internal_compile_foreach.php +++ b/libs/sysplugins/smarty_internal_compile_foreach.php @@ -8,6 +8,7 @@ * @subpackage Compiler * @author Uwe Tews */ + /** * Smarty Internal Plugin Compile Foreach Class */ diff --git a/libs/sysplugins/smarty_internal_compile_function.php b/libs/sysplugins/smarty_internal_compile_function.php index 2226308d..0080704a 100644 --- a/libs/sysplugins/smarty_internal_compile_function.php +++ b/libs/sysplugins/smarty_internal_compile_function.php @@ -8,6 +8,7 @@ * @subpackage Compiler * @author Uwe Tews */ + /** * Smarty Internal Plugin Compile Function Class */ @@ -40,9 +41,9 @@ class Smarty_Internal_Compile_Function extends Smarty_Internal_CompileBase { $output = ''; } else { $output = "<?php if (!function_exists('smarty_template_function_{$_name}')) { - function smarty_template_function_{$_name}(\$_smarty_tpl,\$params) { - \$saved_tpl_vars = \$_smarty_tpl->tpl_vars; - foreach (\$params as \$key => \$value) {\$_smarty_tpl->tpl_vars[\$key] = new Smarty_variable(\$value);}?>"; + function smarty_template_function_{$_name}(\$_smarty_tpl,\$params) { + \$saved_tpl_vars = \$_smarty_tpl->tpl_vars; + foreach (\$params as \$key => \$value) {\$_smarty_tpl->tpl_vars[\$key] = new Smarty_variable(\$value);}?>"; } // Init temporay context $compiler->template->required_plugins = array('compiled' => array(), 'nocache' => array()); diff --git a/libs/sysplugins/smarty_internal_compile_if.php b/libs/sysplugins/smarty_internal_compile_if.php index 9d05f424..4eac8d4b 100644 --- a/libs/sysplugins/smarty_internal_compile_if.php +++ b/libs/sysplugins/smarty_internal_compile_if.php @@ -1,24 +1,25 @@ <?php /** -* Smarty Internal Plugin Compile If -* -* Compiles the {if} {else} {elseif} {/if} tags -* -* @package Smarty -* @subpackage Compiler -* @author Uwe Tews -*/ + * Smarty Internal Plugin Compile If + * + * Compiles the {if} {else} {elseif} {/if} tags + * + * @package Smarty + * @subpackage Compiler + * @author Uwe Tews + */ + /** -* Smarty Internal Plugin Compile If Class -*/ + * Smarty Internal Plugin Compile If Class + */ class Smarty_Internal_Compile_If extends Smarty_Internal_CompileBase { /** - * Compiles code for the {if} tag - * - * @param array $args array with attributes from parser - * @param object $compiler compiler object - * @return string compiled code - */ + * Compiles code for the {if} tag + * + * @param array $args array with attributes from parser + * @param object $compiler compiler object + * @return string compiled code + */ public function compile($args, $compiler) { $this->compiler = $compiler; @@ -37,16 +38,16 @@ class Smarty_Internal_Compile_If extends Smarty_Internal_CompileBase { } /** -* Smarty Internal Plugin Compile Else Class -*/ + * Smarty Internal Plugin Compile Else Class + */ class Smarty_Internal_Compile_Else extends Smarty_Internal_CompileBase { /** - * Compiles code for the {else} tag - * - * @param array $args array with attributes from parser - * @param object $compiler compiler object - * @return string compiled code - */ + * Compiles code for the {else} tag + * + * @param array $args array with attributes from parser + * @param object $compiler compiler object + * @return string compiled code + */ public function compile($args, $compiler) { $this->compiler = $compiler; @@ -58,16 +59,16 @@ class Smarty_Internal_Compile_Else extends Smarty_Internal_CompileBase { } /** -* Smarty Internal Plugin Compile ElseIf Class -*/ + * Smarty Internal Plugin Compile ElseIf Class + */ class Smarty_Internal_Compile_Elseif extends Smarty_Internal_CompileBase { /** - * Compiles code for the {elseif} tag - * - * @param array $args array with attributes from parser - * @param object $compiler compiler object - * @return string compiled code - */ + * Compiles code for the {elseif} tag + * + * @param array $args array with attributes from parser + * @param object $compiler compiler object + * @return string compiled code + */ public function compile($args, $compiler) { $this->compiler = $compiler; @@ -111,4 +112,4 @@ class Smarty_Internal_Compile_Ifclose extends Smarty_Internal_CompileBase { } } -?> +?>
\ No newline at end of file diff --git a/libs/sysplugins/smarty_internal_compile_include.php b/libs/sysplugins/smarty_internal_compile_include.php index 54777b02..91a1e923 100644 --- a/libs/sysplugins/smarty_internal_compile_include.php +++ b/libs/sysplugins/smarty_internal_compile_include.php @@ -9,6 +9,7 @@ * @subpackage Compiler * @author Uwe Tews */ + /** * Smarty Internal Plugin Compile Include Class */ diff --git a/libs/sysplugins/smarty_internal_compile_include_php.php b/libs/sysplugins/smarty_internal_compile_include_php.php index e71f978d..5aa558dd 100644 --- a/libs/sysplugins/smarty_internal_compile_include_php.php +++ b/libs/sysplugins/smarty_internal_compile_include_php.php @@ -1,25 +1,26 @@ <?php /** -* Smarty Internal Plugin Compile Include PHP -* -* Compiles the {include_php} tag -* -* @package Smarty -* @subpackage Compiler -* @author Uwe Tews -*/ + * Smarty Internal Plugin Compile Include PHP + * + * Compiles the {include_php} tag + * + * @package Smarty + * @subpackage Compiler + * @author Uwe Tews + */ + /** -* Smarty Internal Plugin Compile Insert Class -*/ + * Smarty Internal Plugin Compile Insert Class + */ class Smarty_Internal_Compile_Include_Php extends Smarty_Internal_CompileBase { /** - * Compiles code for the {include_php} tag - * - * @param array $args array with attributes from parser - * @param object $compiler compiler object - * @return string compiled code - */ + * Compiles code for the {include_php} tag + * + * @param array $args array with attributes from parser + * @param object $compiler compiler object + * @return string compiled code + */ public function compile($args, $compiler) { $this->compiler = $compiler; @@ -65,4 +66,4 @@ class Smarty_Internal_Compile_Include_Php extends Smarty_Internal_CompileBase { } } -?> +?>
\ No newline at end of file diff --git a/libs/sysplugins/smarty_internal_compile_insert.php b/libs/sysplugins/smarty_internal_compile_insert.php index ae491002..94c9b3aa 100644 --- a/libs/sysplugins/smarty_internal_compile_insert.php +++ b/libs/sysplugins/smarty_internal_compile_insert.php @@ -9,6 +9,7 @@ * @subpackage Compiler * @author Uwe Tews */ + /** * Smarty Internal Plugin Compile Insert Class */ diff --git a/libs/sysplugins/smarty_internal_compile_ldelim.php b/libs/sysplugins/smarty_internal_compile_ldelim.php index c809990c..9f6294ca 100644 --- a/libs/sysplugins/smarty_internal_compile_ldelim.php +++ b/libs/sysplugins/smarty_internal_compile_ldelim.php @@ -1,25 +1,26 @@ <?php /** -* Smarty Internal Plugin Compile Ldelim -* -* Compiles the {ldelim} tag -* @package Smarty -* @subpackage Compiler -* @author Uwe Tews -*/ + * Smarty Internal Plugin Compile Ldelim + * + * Compiles the {ldelim} tag + * @package Smarty + * @subpackage Compiler + * @author Uwe Tews + */ + /** -* Smarty Internal Plugin Compile Ldelim Class -*/ + * Smarty Internal Plugin Compile Ldelim Class + */ class Smarty_Internal_Compile_Ldelim extends Smarty_Internal_CompileBase { /** - * Compiles code for the {ldelim} tag - * - * This tag does output the left delimiter - * @param array $args array with attributes from parser - * @param object $compiler compiler object - * @return string compiled code - */ + * Compiles code for the {ldelim} tag + * + * This tag does output the left delimiter + * @param array $args array with attributes from parser + * @param object $compiler compiler object + * @return string compiled code + */ public function compile($args, $compiler) { $this->compiler = $compiler; @@ -28,5 +29,6 @@ class Smarty_Internal_Compile_Ldelim extends Smarty_Internal_CompileBase { $this->compiler->has_code = true; return $this->compiler->smarty->left_delimiter; } -} +} + ?> diff --git a/libs/sysplugins/smarty_internal_compile_nocache.php b/libs/sysplugins/smarty_internal_compile_nocache.php index ebeef9dd..3a4e1135 100644 --- a/libs/sysplugins/smarty_internal_compile_nocache.php +++ b/libs/sysplugins/smarty_internal_compile_nocache.php @@ -1,25 +1,26 @@ <?php /** -* Smarty Internal Plugin Compile Nocache -* -* Compiles the {nocache} {/nocache} tags -* @package Smarty -* @subpackage Compiler -* @author Uwe Tews -*/ + * Smarty Internal Plugin Compile Nocache + * + * Compiles the {nocache} {/nocache} tags + * @package Smarty + * @subpackage Compiler + * @author Uwe Tews + */ + /** -* Smarty Internal Plugin Compile Nocache Class -*/ + * Smarty Internal Plugin Compile Nocache Class + */ class Smarty_Internal_Compile_Nocache extends Smarty_Internal_CompileBase { /** - * Compiles code for the {nocache} tag - * - * This tag does not generate compiled output. It only sets a compiler flag - * @param array $args array with attributes from parser - * @param object $compiler compiler object - * @return string compiled code - */ + * Compiles code for the {nocache} tag + * + * This tag does not generate compiled output. It only sets a compiler flag + * @param array $args array with attributes from parser + * @param object $compiler compiler object + * @return string compiled code + */ public function compile($args, $compiler) { $this->compiler = $compiler; @@ -33,17 +34,17 @@ class Smarty_Internal_Compile_Nocache extends Smarty_Internal_CompileBase { } /** -* Smarty Internal Plugin Compile Nocacheclose Class -*/ + * Smarty Internal Plugin Compile Nocacheclose Class + */ class Smarty_Internal_Compile_Nocacheclose extends Smarty_Internal_CompileBase { /** - * Compiles code for the {/nocache} tag - * - * This tag does not generate compiled output. It only sets a compiler flag - * @param array $args array with attributes from parser - * @param object $compiler compiler object - * @return string compiled code - */ + * Compiles code for the {/nocache} tag + * + * This tag does not generate compiled output. It only sets a compiler flag + * @param array $args array with attributes from parser + * @param object $compiler compiler object + * @return string compiled code + */ public function compile($args, $compiler) { $this->compiler = $compiler; @@ -56,4 +57,4 @@ class Smarty_Internal_Compile_Nocacheclose extends Smarty_Internal_CompileBase { } } -?> +?>
\ No newline at end of file diff --git a/libs/sysplugins/smarty_internal_compile_private_block_plugin.php b/libs/sysplugins/smarty_internal_compile_private_block_plugin.php index 75df766b..79772a12 100644 --- a/libs/sysplugins/smarty_internal_compile_private_block_plugin.php +++ b/libs/sysplugins/smarty_internal_compile_private_block_plugin.php @@ -8,6 +8,7 @@ * @subpackage Compiler * @author Uwe Tews */ + /** * Smarty Internal Plugin Compile Block Plugin Class */ diff --git a/libs/sysplugins/smarty_internal_compile_private_function_plugin.php b/libs/sysplugins/smarty_internal_compile_private_function_plugin.php index 9abb5829..77f83c0d 100644 --- a/libs/sysplugins/smarty_internal_compile_private_function_plugin.php +++ b/libs/sysplugins/smarty_internal_compile_private_function_plugin.php @@ -8,6 +8,7 @@ * @subpackage Compiler * @author Uwe Tews */ + /** * Smarty Internal Plugin Compile Function Plugin Class */ diff --git a/libs/sysplugins/smarty_internal_compile_private_modifier.php b/libs/sysplugins/smarty_internal_compile_private_modifier.php index d96f16fe..ae5dcfa2 100644 --- a/libs/sysplugins/smarty_internal_compile_private_modifier.php +++ b/libs/sysplugins/smarty_internal_compile_private_modifier.php @@ -8,6 +8,7 @@ * @subpackage Compiler
* @author Uwe Tews
*/
+
/**
* Smarty Internal Plugin Compile Modifier Class
*/
diff --git a/libs/sysplugins/smarty_internal_compile_private_object_block_function.php b/libs/sysplugins/smarty_internal_compile_private_object_block_function.php index ba4d5000..83558bfc 100644 --- a/libs/sysplugins/smarty_internal_compile_private_object_block_function.php +++ b/libs/sysplugins/smarty_internal_compile_private_object_block_function.php @@ -1,26 +1,27 @@ <?php /** -* Smarty Internal Plugin Compile Object Block Function -* -* Compiles code for registered objects as block function -* -* @package Smarty -* @subpackage Compiler -* @author Uwe Tews -*/ + * Smarty Internal Plugin Compile Object Block Function + * + * Compiles code for registered objects as block function + * + * @package Smarty + * @subpackage Compiler + * @author Uwe Tews + */ + /** -* Smarty Internal Plugin Compile Object Block Function Class -*/ + * Smarty Internal Plugin Compile Object Block Function Class + */ class Smarty_Internal_Compile_Private_Object_Block_Function extends Smarty_Internal_CompileBase { /** - * Compiles code for the execution of block plugin - * - * @param array $args array with attributes from parser - * @param string $tag name of block function - * @param string $methode name of methode to call - * @param object $compiler compiler object - * @return string compiled code - */ + * Compiles code for the execution of block plugin + * + * @param array $args array with attributes from parser + * @param string $tag name of block function + * @param string $methode name of methode to call + * @param object $compiler compiler object + * @return string compiled code + */ public function compile($args, $compiler, $tag, $methode) { $this->compiler = $compiler; diff --git a/libs/sysplugins/smarty_internal_compile_private_object_function.php b/libs/sysplugins/smarty_internal_compile_private_object_function.php index 3cf90d8e..32bdbdce 100644 --- a/libs/sysplugins/smarty_internal_compile_private_object_function.php +++ b/libs/sysplugins/smarty_internal_compile_private_object_function.php @@ -8,6 +8,7 @@ * @subpackage Compiler * @author Uwe Tews */ + /** * Smarty Internal Plugin Compile Object Function Class */ @@ -55,8 +56,9 @@ class Smarty_Internal_Compile_Private_Object_Function extends Smarty_Internal_Co $output = "<?php echo {$return};?>\n"; } else { $output = "<?php \$_smarty_tpl->assign({$_assign},{$return});?>\n"; - } + } return $output; } -} +} + ?>
\ No newline at end of file diff --git a/libs/sysplugins/smarty_internal_compile_private_print_expression.php b/libs/sysplugins/smarty_internal_compile_private_print_expression.php index b66cc252..850917d4 100644 --- a/libs/sysplugins/smarty_internal_compile_private_print_expression.php +++ b/libs/sysplugins/smarty_internal_compile_private_print_expression.php @@ -8,6 +8,7 @@ * @subpackage Compiler * @author Uwe Tews */ + /** * Smarty Internal Plugin Compile Print Expression Class */ @@ -58,7 +59,7 @@ class Smarty_Internal_Compile_Private_Print_Expression extends Smarty_Internal_C if (isset($_attr['modifierlist'])) { $output = $this->compiler->compileTag('private_modifier', array('modifierlist' => $_attr['modifierlist'], 'value' => $output)); } - $this->compiler->has_output = true; + $this->compiler->has_output = true; $output = '<?php echo ' . $output . ';?>'; } return $output; diff --git a/libs/sysplugins/smarty_internal_compile_private_registered_block.php b/libs/sysplugins/smarty_internal_compile_private_registered_block.php index f879f715..39ad5903 100644 --- a/libs/sysplugins/smarty_internal_compile_private_registered_block.php +++ b/libs/sysplugins/smarty_internal_compile_private_registered_block.php @@ -1,25 +1,26 @@ <?php
/**
-* Smarty Internal Plugin Compile Registered Block
-*
-* Compiles code for the execution of a registered block function
-*
-* @package Smarty
-* @subpackage Compiler
-* @author Uwe Tews
-*/
+ * Smarty Internal Plugin Compile Registered Block
+ *
+ * Compiles code for the execution of a registered block function
+ *
+ * @package Smarty
+ * @subpackage Compiler
+ * @author Uwe Tews
+ */
+
/**
-* Smarty Internal Plugin Compile Registered Block Class
-*/
+ * Smarty Internal Plugin Compile Registered Block Class
+ */
class Smarty_Internal_Compile_Private_Registered_Block extends Smarty_Internal_CompileBase {
/**
- * Compiles code for the execution of a block function
- *
- * @param array $args array with attributes from parser
- * @param string $tag name of block function
- * @param object $compiler compiler object
- * @return string compiled code
- */
+ * Compiles code for the execution of a block function
+ *
+ * @param array $args array with attributes from parser
+ * @param string $tag name of block function
+ * @param object $compiler compiler object
+ * @return string compiled code
+ */
public function compile($args, $compiler, $tag)
{
$this->compiler = $compiler;
diff --git a/libs/sysplugins/smarty_internal_compile_private_registered_function.php b/libs/sysplugins/smarty_internal_compile_private_registered_function.php index bf4e728c..3590beac 100644 --- a/libs/sysplugins/smarty_internal_compile_private_registered_function.php +++ b/libs/sysplugins/smarty_internal_compile_private_registered_function.php @@ -8,6 +8,7 @@ * @subpackage Compiler
* @author Uwe Tews
*/
+
/**
* Smarty Internal Plugin Compile Registered Function Class
*/
diff --git a/libs/sysplugins/smarty_internal_compile_private_special_variable.php b/libs/sysplugins/smarty_internal_compile_private_special_variable.php index 9a7dbcfb..cd90a119 100644 --- a/libs/sysplugins/smarty_internal_compile_private_special_variable.php +++ b/libs/sysplugins/smarty_internal_compile_private_special_variable.php @@ -1,24 +1,25 @@ <?php /** -* Smarty Internal Plugin Compile Special Smarty Variable -* -* Compiles the special $smarty variables -* -* @package Smarty -* @subpackage Compiler -* @author Uwe Tews -*/ + * Smarty Internal Plugin Compile Special Smarty Variable + * + * Compiles the special $smarty variables + * + * @package Smarty + * @subpackage Compiler + * @author Uwe Tews + */ + /** -* Smarty Internal Plugin Compile special Smarty Variable Class -*/ + * Smarty Internal Plugin Compile special Smarty Variable Class + */ class Smarty_Internal_Compile_Private_Special_Variable extends Smarty_Internal_CompileBase { /** - * Compiles code for the speical $smarty variables - * - * @param array $args array with attributes from parser - * @param object $compiler compiler object - * @return string compiled code - */ + * Compiles code for the speical $smarty variables + * + * @param array $args array with attributes from parser + * @param object $compiler compiler object + * @return string compiled code + */ public function compile($args, $compiler) { $_index = explode(',', str_replace(array(']['), array(','), substr($args, 1, strlen($args)-2))); diff --git a/libs/sysplugins/smarty_internal_compile_rdelim.php b/libs/sysplugins/smarty_internal_compile_rdelim.php index 88c4e1e5..e8f3eb24 100644 --- a/libs/sysplugins/smarty_internal_compile_rdelim.php +++ b/libs/sysplugins/smarty_internal_compile_rdelim.php @@ -1,25 +1,26 @@ <?php /** -* Smarty Internal Plugin Compile Rdelim -* -* Compiles the {rdelim} tag -* @package Smarty -* @subpackage Compiler -* @author Uwe Tews -*/ + * Smarty Internal Plugin Compile Rdelim + * + * Compiles the {rdelim} tag + * @package Smarty + * @subpackage Compiler + * @author Uwe Tews + */ + /** -* Smarty Internal Plugin Compile Rdelim Class -*/ + * Smarty Internal Plugin Compile Rdelim Class + */ class Smarty_Internal_Compile_Rdelim extends Smarty_Internal_CompileBase { /** - * Compiles code for the {rdelim} tag - * - * This tag does output the right delimiter - * @param array $args array with attributes from parser - * @param object $compiler compiler object - * @return string compiled code - */ + * Compiles code for the {rdelim} tag + * + * This tag does output the right delimiter + * @param array $args array with attributes from parser + * @param object $compiler compiler object + * @return string compiled code + */ public function compile($args, $compiler) { $this->compiler = $compiler; @@ -28,5 +29,6 @@ class Smarty_Internal_Compile_Rdelim extends Smarty_Internal_CompileBase { $this->compiler->has_code = true; return $this->compiler->smarty->right_delimiter; } -} -?> +} + +?>
\ No newline at end of file diff --git a/libs/sysplugins/smarty_internal_compile_section.php b/libs/sysplugins/smarty_internal_compile_section.php index 0de506a7..50c82722 100644 --- a/libs/sysplugins/smarty_internal_compile_section.php +++ b/libs/sysplugins/smarty_internal_compile_section.php @@ -1,24 +1,25 @@ <?php /** -* Smarty Internal Plugin Compile Section -* -* Compiles the {section} {sectionelse} {/section} tags -* -* @package Smarty -* @subpackage Compiler -* @author Uwe Tews -*/ + * Smarty Internal Plugin Compile Section + * + * Compiles the {section} {sectionelse} {/section} tags + * + * @package Smarty + * @subpackage Compiler + * @author Uwe Tews + */ + /** -* Smarty Internal Plugin Compile Section Class -*/ + * Smarty Internal Plugin Compile Section Class + */ class Smarty_Internal_Compile_Section extends Smarty_Internal_CompileBase { /** - * Compiles code for the {section} tag - * - * @param array $args array with attributes from parser - * @param object $compiler compiler object - * @return string compiled code - */ + * Compiles code for the {section} tag + * + * @param array $args array with attributes from parser + * @param object $compiler compiler object + * @return string compiled code + */ public function compile($args, $compiler) { $this->compiler = $compiler; @@ -28,8 +29,8 @@ class Smarty_Internal_Compile_Section extends Smarty_Internal_CompileBase { $_attr = $this->_get_attributes($args); $this->_open_tag('section', array('section',$this->compiler->nocache)); - // maybe nocache because of nocache variables - $this->compiler->nocache = $this->compiler->nocache | $this->compiler->tag_nocache; + // maybe nocache because of nocache variables + $this->compiler->nocache = $this->compiler->nocache | $this->compiler->tag_nocache; $output = "<?php "; @@ -116,12 +117,12 @@ class Smarty_Internal_Compile_Section extends Smarty_Internal_CompileBase { */ class Smarty_Internal_Compile_Sectionelse extends Smarty_Internal_CompileBase { /** - * Compiles code for the {sectionelse} tag - * - * @param array $args array with attributes from parser - * @param object $compiler compiler object - * @return string compiled code - */ + * Compiles code for the {sectionelse} tag + * + * @param array $args array with attributes from parser + * @param object $compiler compiler object + * @return string compiled code + */ public function compile($args, $compiler) { $this->compiler = $compiler; @@ -136,24 +137,24 @@ class Smarty_Internal_Compile_Sectionelse extends Smarty_Internal_CompileBase { } /** -* Smarty Internal Plugin Compile Sectionclose Class -*/ + * Smarty Internal Plugin Compile Sectionclose Class + */ class Smarty_Internal_Compile_Sectionclose extends Smarty_Internal_CompileBase { /** - * Compiles code for the {/section} tag - * - * @param array $args array with attributes from parser - * @param object $compiler compiler object - * @return string compiled code - */ + * Compiles code for the {/section} tag + * + * @param array $args array with attributes from parser + * @param object $compiler compiler object + * @return string compiled code + */ public function compile($args, $compiler) { $this->compiler = $compiler; // check and get attributes $_attr = $this->_get_attributes($args); - // must endblock be nocache? - if ($this->compiler->nocache) { + // must endblock be nocache? + if ($this->compiler->nocache) { $this->compiler->tag_nocache = true; } @@ -166,5 +167,4 @@ class Smarty_Internal_Compile_Sectionclose extends Smarty_Internal_CompileBase { } } - -?> +?>
\ No newline at end of file diff --git a/libs/sysplugins/smarty_internal_compile_while.php b/libs/sysplugins/smarty_internal_compile_while.php index 6dc18046..1a0d8dd4 100644 --- a/libs/sysplugins/smarty_internal_compile_while.php +++ b/libs/sysplugins/smarty_internal_compile_while.php @@ -8,6 +8,7 @@ * @subpackage Compiler * @author Uwe Tews */ + /** * Smarty Internal Plugin Compile While Class */ @@ -28,9 +29,9 @@ class Smarty_Internal_Compile_While extends Smarty_Internal_CompileBase { $this->_open_tag('while', $this->compiler->nocache); // maybe nocache because of nocache variables - $this->compiler->nocache = $this->compiler->nocache | $this->compiler->tag_nocache; + $this->compiler->nocache = $this->compiler->nocache | $this->compiler->tag_nocache; - + if (is_array($args['if condition'])) { $_output = " <?php if (!isset(\$_smarty_tpl->tpl_vars[".$args['if condition']['var']."])) \$_smarty_tpl->tpl_vars[".$args['if condition']['var']."] = new Smarty_Variable;\n"; $_output .= " while (\$_smarty_tpl->tpl_vars[".$args['if condition']['var']."]->value = ".$args['if condition']['value'].") {\n ?>"; @@ -55,12 +56,13 @@ class Smarty_Internal_Compile_Whileclose extends Smarty_Internal_CompileBase { public function compile($args, $compiler) { $this->compiler = $compiler; - // must endblock be nocache? - if ($this->compiler->nocache) { + // must endblock be nocache? + if ($this->compiler->nocache) { $this->compiler->tag_nocache = true; } $this->compiler->nocache = $this->_close_tag(array('while')); return "<?php }?>"; } } -?> + +?>
\ No newline at end of file diff --git a/libs/sysplugins/smarty_internal_config_file_compiler.php b/libs/sysplugins/smarty_internal_config_file_compiler.php index af956464..469dab27 100644 --- a/libs/sysplugins/smarty_internal_config_file_compiler.php +++ b/libs/sysplugins/smarty_internal_config_file_compiler.php @@ -10,6 +10,7 @@ * @subpackage Config * @author Uwe Tews */ + /** * Main config file compiler class */ diff --git a/libs/sysplugins/smarty_internal_configfilelexer.php b/libs/sysplugins/smarty_internal_configfilelexer.php index 50d9fd69..3c4249c8 100644 --- a/libs/sysplugins/smarty_internal_configfilelexer.php +++ b/libs/sysplugins/smarty_internal_configfilelexer.php @@ -7,6 +7,7 @@ * @subpackage Config * @author Uwe Tews */ + /** * Smarty Internal Plugin Configfilelexer */ @@ -20,10 +21,10 @@ class Smarty_Internal_Configfilelexer public $node; public $line; private $state = 1; - public $smarty_token_names = array ( // Text for parser error messages - ); - - + public $smarty_token_names = array ( // Text for parser error messages + ); + + function __construct($data, $smarty) { // set instance object @@ -521,6 +522,6 @@ class Smarty_Internal_Configfilelexer $this->yypopstate(); } - } -?> + +?>
\ No newline at end of file diff --git a/libs/sysplugins/smarty_internal_configfileparser.php b/libs/sysplugins/smarty_internal_configfileparser.php index 3cd3f0f0..d8bb95c2 100644 --- a/libs/sysplugins/smarty_internal_configfileparser.php +++ b/libs/sysplugins/smarty_internal_configfileparser.php @@ -164,7 +164,7 @@ class Smarty_Internal_Configfileparser#line 79 "smarty_internal_configfileparser private function add_global_vars(Array $vars) { if (!isset($this->compiler->config_data['vars'])) { - $this->compiler->config_data['vars'] = Array(); + $this->compiler->config_data['vars'] = Array(); } foreach ($vars as $var) { $this->set_var($var, $this->compiler->config_data); @@ -404,7 +404,7 @@ static public $yy_action = array( $this->yystack[$this->yyidx]->stateno, self::$yyRuleInfo[$yyruleno]['lhs']); if (isset(self::$yyExpectedTokens[$nextstate])) { - $expected = array_merge($expected, self::$yyExpectedTokens[$nextstate]); + $expected = array_merge($expected, self::$yyExpectedTokens[$nextstate]); if (in_array($token, self::$yyExpectedTokens[$nextstate], true)) { $this->yyidx = $yyidx; @@ -439,8 +439,8 @@ static public $yy_action = array( } break; } while (true); - $this->yyidx = $yyidx; - $this->yystack = $stack; + $this->yyidx = $yyidx; + $this->yystack = $stack; return array_unique($expected); } @@ -868,4 +868,5 @@ static public $yy_action = array( } while ($yymajor != self::YYNOCODE && $this->yyidx >= 0); } } + ?>
\ No newline at end of file diff --git a/libs/sysplugins/smarty_internal_debug.php b/libs/sysplugins/smarty_internal_debug.php index 054a3735..ad1091b5 100644 --- a/libs/sysplugins/smarty_internal_debug.php +++ b/libs/sysplugins/smarty_internal_debug.php @@ -9,6 +9,7 @@ * @subpackage Debug * @author Uwe Tews */ + /** * Smarty Internal Plugin Debug Class */ diff --git a/libs/sysplugins/smarty_internal_function_call_handler.php b/libs/sysplugins/smarty_internal_function_call_handler.php index 48bee427..543c77b4 100644 --- a/libs/sysplugins/smarty_internal_function_call_handler.php +++ b/libs/sysplugins/smarty_internal_function_call_handler.php @@ -6,6 +6,7 @@ * @subpackage PluginsInternal
* @author Uwe Tews
*/
+
/**
* This class does call function defined with the {function} tag
*/
@@ -20,8 +21,8 @@ class Smarty_Internal_Function_Call_Handler extends Smarty_Internal_Template { }
if (!is_callable($_function)) {
$_code = "function {$_function}(\$_smarty_tpl,\$params) {
- \$saved_tpl_vars = \$_smarty_tpl->tpl_vars;
- foreach (\$params as \$key => \$value) {\$_smarty_tpl->tpl_vars[\$key] = new Smarty_variable(\$value);}?>";
+ \$saved_tpl_vars = \$_smarty_tpl->tpl_vars;
+ foreach (\$params as \$key => \$value) {\$_smarty_tpl->tpl_vars[\$key] = new Smarty_variable(\$value);}?>";
if ($_nocache) {
$_code .= preg_replace(array("!<\?php echo \\'/\*%%SmartyNocache:{$_template->smarty->template_functions[$_name]['nocache_hash']}%%\*/|/\*/%%SmartyNocache:{$_template->smarty->template_functions[$_name]['nocache_hash']}%%\*/\\';\?>!",
"!\\\'!"), array('', "'"), $_template->smarty->template_functions[$_name]['compiled']);
diff --git a/libs/sysplugins/smarty_internal_nocache_insert.php b/libs/sysplugins/smarty_internal_nocache_insert.php index ea593832..ae11a7ce 100644 --- a/libs/sysplugins/smarty_internal_nocache_insert.php +++ b/libs/sysplugins/smarty_internal_nocache_insert.php @@ -9,6 +9,7 @@ * @subpackage Compiler
* @author Uwe Tews
*/
+
/**
* Smarty Internal Plugin Compile Insert Class
*/
diff --git a/libs/sysplugins/smarty_internal_parsetree.php b/libs/sysplugins/smarty_internal_parsetree.php index 19e4a94b..d3bcb22d 100644 --- a/libs/sysplugins/smarty_internal_parsetree.php +++ b/libs/sysplugins/smarty_internal_parsetree.php @@ -9,13 +9,14 @@ * @author Thue Kristensen
* @author Uwe Tews
*/
+
abstract class _smarty_parsetree {
abstract public function to_smarty_php();
}
-
-/* A complete smarty tag. */
-
+/**
+ * A complete smarty tag.
+ */
class _smarty_tag extends _smarty_parsetree
{
public $parser;
@@ -42,7 +43,9 @@ class _smarty_tag extends _smarty_parsetree }
}
-/* Code fragment inside a tag. */
+/**
+ * Code fragment inside a tag.
+ */
class _smarty_code extends _smarty_parsetree {
public $parser;
public $data;
@@ -58,7 +61,9 @@ class _smarty_code extends _smarty_parsetree { }
}
-/* Double quoted string inside a tag. */
+/**
+ * Double quoted string inside a tag.
+ */
class _smarty_doublequoted extends _smarty_parsetree {
public $parser;
public $subtrees = Array();
@@ -113,7 +118,9 @@ class _smarty_doublequoted extends _smarty_parsetree { }
}
-/* Raw chars as part of a double quoted string. */
+/**
+ * Raw chars as part of a double quoted string.
+ */
class _smarty_dq_content extends _smarty_parsetree {
public $data;
function __construct($parser, $data)
@@ -127,7 +134,10 @@ class _smarty_dq_content extends _smarty_parsetree { return '"' . $this->data . '"';
}
}
-/* Template element */
+
+/**
+ * Template element
+ */
class _smarty_template_buffer extends _smarty_parsetree {
public $subtrees = Array();
function __construct($parser)
@@ -160,7 +170,7 @@ class _smarty_template_buffer extends _smarty_parsetree { $code = substr($code, 0, strlen($code)-1) . '<<?php ?>?' . substr($subtree, 1);
} elseif ($this->parser->asp_tags && substr($subtree, 0, 1) == '%') {
$code = substr($code, 0, strlen($code)-1) . '<<?php ?>%' . substr($subtree, 1);
- } else {
+ } else {
$code .= $subtree;
}
continue;
@@ -169,7 +179,7 @@ class _smarty_template_buffer extends _smarty_parsetree { $subtree = $this->subtrees[$key]->to_smarty_php();
if (substr($subtree, 0, 1) == '>') {
$code = substr($code, 0, strlen($code)-1) . '%<?php ?>>' . substr($subtree, 1);
- } else {
+ } else {
$code .= $subtree;
}
continue;
@@ -178,7 +188,7 @@ class _smarty_template_buffer extends _smarty_parsetree { $subtree = $this->subtrees[$key]->to_smarty_php();
if (substr($subtree, 0, 1) == '>') {
$code = substr($code, 0, strlen($code)-1) . '?<?php ?>>' . substr($subtree, 1);
- } else {
+ } else {
$code .= $subtree;
}
continue;
@@ -187,8 +197,11 @@ class _smarty_template_buffer extends _smarty_parsetree { }
return $code;
}
-}
-/* template text */
+}
+
+/**
+ * template text
+ */
class _smarty_text extends _smarty_parsetree {
public $data;
function __construct($parser, $data)
@@ -202,7 +215,10 @@ class _smarty_text extends _smarty_parsetree { return $this->data;
}
}
-/* template linebreaks */
+
+/**
+ * template linebreaks
+ */
class _smarty_linebreak extends _smarty_parsetree {
public $data;
function __construct($parser, $data)
diff --git a/libs/sysplugins/smarty_internal_register.php b/libs/sysplugins/smarty_internal_register.php index e6ae0318..a1e3acd0 100644 --- a/libs/sysplugins/smarty_internal_register.php +++ b/libs/sysplugins/smarty_internal_register.php @@ -260,3 +260,5 @@ class Smarty_Internal_Register { } } } + +?>
\ No newline at end of file diff --git a/libs/sysplugins/smarty_internal_resource_extends.php b/libs/sysplugins/smarty_internal_resource_extends.php index b684aadd..db078a33 100644 --- a/libs/sysplugins/smarty_internal_resource_extends.php +++ b/libs/sysplugins/smarty_internal_resource_extends.php @@ -9,6 +9,7 @@ * @subpackage TemplateResources * @author Uwe Tews */ + /** * Smarty Internal Plugin Resource Extends */ @@ -127,14 +128,18 @@ class Smarty_Internal_Resource_Extends { } } // $_template->template_filepath = $saved_filepath; - } + } + + /** + * saveBlockData + */ protected function saveBlockData($block_content, $block_tag, $_filepath) { if (0 == preg_match("!(.?)(name=)(.*?)(?=(\s|{$this->_rdl}))!", $block_tag, $_match)) { $this->smarty->trigger_error("'{$block_tag}' missing name attribute in file '$_filepath'"); } else { $_name = trim($_match[3], '\'"'); - // replace {$smarty.block.child} + // replace {$smarty.block.child} if (strpos($block_content, $this->smarty->left_delimiter . '$smarty.block.child' . $this->smarty->right_delimiter) !== false) { if (isset($this->smarty->block_data[$_name])) { $block_content = str_replace($this->smarty->left_delimiter . '$smarty.block.child' . $this->smarty->right_delimiter, diff --git a/libs/sysplugins/smarty_internal_resource_file.php b/libs/sysplugins/smarty_internal_resource_file.php index b84f5807..abdd6c5a 100644 --- a/libs/sysplugins/smarty_internal_resource_file.php +++ b/libs/sysplugins/smarty_internal_resource_file.php @@ -1,17 +1,18 @@ <?php /** -* Smarty Internal Plugin Resource File -* -* Implements the file system as resource for Smarty templates -* -* @package Smarty -* @subpackage TemplateResources -* @author Uwe Tews -*/ -/** -* Smarty Internal Plugin Resource File -*/ + * Smarty Internal Plugin Resource File + * + * Implements the file system as resource for Smarty templates + * + * @package Smarty + * @subpackage TemplateResources + * @author Uwe Tews + */ + +/** + * Smarty Internal Plugin Resource File + */ class Smarty_Internal_Resource_File { public function __construct($smarty) { @@ -26,10 +27,10 @@ class Smarty_Internal_Resource_File { public $isEvaluated = false; /** - * Return flag if template source is existing - * - * @return boolean true - */ + * Return flag if template source is existing + * + * @return boolean true + */ public function isExisting($template) { if ($template->getTemplateFilepath() === false) { @@ -40,11 +41,11 @@ class Smarty_Internal_Resource_File { } /** - * Get filepath to template source - * - * @param object $_template template object - * @return string filepath to template source file - */ + * Get filepath to template source + * + * @param object $_template template object + * @return string filepath to template source file + */ public function getTemplateFilepath($_template) { $_filepath = $_template->buildTemplateFilepath (); @@ -59,22 +60,22 @@ class Smarty_Internal_Resource_File { } /** - * Get timestamp to template source - * - * @param object $_template template object - * @return integer timestamp of template source file - */ + * Get timestamp to template source + * + * @param object $_template template object + * @return integer timestamp of template source file + */ public function getTemplateTimestamp($_template) { return filemtime($_template->getTemplateFilepath()); } /** - * Read template source from file - * - * @param object $_template template object - * @return string content of template source file - */ + * Read template source from file + * + * @param object $_template template object + * @return string content of template source file + */ public function getTemplateSource($_template) { // read template file @@ -87,11 +88,11 @@ class Smarty_Internal_Resource_File { } /** - * Get filepath to compiled template - * - * @param object $_template template object - * @return string return path to compiled template - */ + * Get filepath to compiled template + * + * @param object $_template template object + * @return string return path to compiled template + */ public function getCompiledFilepath($_template) { $_compile_id = isset($_template->compile_id) ? preg_replace('![^\w\|]+!', '_', $_template->compile_id) : null; @@ -124,4 +125,4 @@ class Smarty_Internal_Resource_File { } } -?> +?>
\ No newline at end of file diff --git a/libs/sysplugins/smarty_internal_resource_php.php b/libs/sysplugins/smarty_internal_resource_php.php index a2942222..d0d285f6 100644 --- a/libs/sysplugins/smarty_internal_resource_php.php +++ b/libs/sysplugins/smarty_internal_resource_php.php @@ -1,21 +1,22 @@ <?php /** -* Smarty Internal Plugin Resource PHP -* -* Implements the file system as resource for PHP templates -* -* @package Smarty -* @subpackage TemplateResources -* @author Uwe Tews -*/ + * Smarty Internal Plugin Resource PHP + * + * Implements the file system as resource for PHP templates + * + * @package Smarty + * @subpackage TemplateResources + * @author Uwe Tews + */ + /** -* Smarty Internal Plugin Resource PHP -*/ + * Smarty Internal Plugin Resource PHP + */ class Smarty_Internal_Resource_PHP { /** - * Class constructor, enable short open tags - */ + * Class constructor, enable short open tags + */ public function __construct($smarty) { $this->smarty = $smarty; @@ -26,10 +27,10 @@ class Smarty_Internal_Resource_PHP { public $isEvaluated = false; /** - * Return flag if template source is existing - * - * @return boolean true - */ + * Return flag if template source is existing + * + * @return boolean true + */ public function isExisting($template) { if ($template->getTemplateFilepath() === false) { @@ -40,11 +41,11 @@ class Smarty_Internal_Resource_PHP { } /** - * Get filepath to template source - * - * @param object $_template template object - * @return string filepath to template source file - */ + * Get filepath to template source + * + * @param object $_template template object + * @return string filepath to template source file + */ public function getTemplateFilepath($_template) { $_filepath = $_template->buildTemplateFilepath (); @@ -57,22 +58,22 @@ class Smarty_Internal_Resource_PHP { } /** - * Get timestamp to template source - * - * @param object $_template template object - * @return integer timestamp of template source file - */ + * Get timestamp to template source + * + * @param object $_template template object + * @return integer timestamp of template source file + */ public function getTemplateTimestamp($_template) { return filemtime($_template->getTemplateFilepath()); } /** - * Read template source from file - * - * @param object $_template template object - * @return string content of template source file - */ + * Read template source from file + * + * @param object $_template template object + * @return string content of template source file + */ public function getTemplateSource($_template) { if (file_exists($_template->getTemplateFilepath())) { @@ -83,13 +84,12 @@ class Smarty_Internal_Resource_PHP { } } - /** - * Get filepath to compiled template - * - * @param object $_template template object - * @return boolean return false as compiled template is not stored - */ + * Get filepath to compiled template + * + * @param object $_template template object + * @return boolean return false as compiled template is not stored + */ public function getCompiledFilepath($_template) { // no filepath for PHP templates @@ -97,8 +97,8 @@ class Smarty_Internal_Resource_PHP { } /** - * renders the PHP template - */ + * renders the PHP template + */ public function renderUncompiled($_smarty_template) { if (!$this->smarty->allow_php_templates) { diff --git a/libs/sysplugins/smarty_internal_resource_registered.php b/libs/sysplugins/smarty_internal_resource_registered.php index 92347a17..a56236e4 100644 --- a/libs/sysplugins/smarty_internal_resource_registered.php +++ b/libs/sysplugins/smarty_internal_resource_registered.php @@ -1,18 +1,18 @@ <?php /** -* Smarty Internal Plugin Resource Registered -* -* Implements the registered resource for Smarty template -* -* @package Smarty -* @subpackage TemplateResources -* @author Uwe Tews -*/ + * Smarty Internal Plugin Resource Registered + * + * Implements the registered resource for Smarty template + * + * @package Smarty + * @subpackage TemplateResources + * @author Uwe Tews + */ + /** -* Smarty Internal Plugin Resource Registered -*/ - + * Smarty Internal Plugin Resource Registered + */ class Smarty_Internal_Resource_Registered { public function __construct($smarty) { @@ -27,10 +27,10 @@ class Smarty_Internal_Resource_Registered { public $isEvaluated = false; /** - * Return flag if template source is existing - * - * @return boolean true - */ + * Return flag if template source is existing + * + * @return boolean true + */ public function isExisting($_template) { if (is_integer($_template->getTemplateTimestamp())) { @@ -40,11 +40,11 @@ class Smarty_Internal_Resource_Registered { } } /** - * Get filepath to template source - * - * @param object $_template template object - * @return string return 'string' as template source is not a file - */ + * Get filepath to template source + * + * @param object $_template template object + * @return string return 'string' as template source is not a file + */ public function getTemplateFilepath($_template) { // no filepath for strings @@ -52,14 +52,14 @@ class Smarty_Internal_Resource_Registered { $_filepath = $_template->resource_type .':'.$_template->resource_name; $_template->templateUid = sha1($_filepath); return $_filepath; - } + } /** - * Get timestamp to template source - * - * @param object $_template template object - * @return boolean false as string resources have no timestamp - */ + * Get timestamp to template source + * + * @param object $_template template object + * @return boolean false as string resources have no timestamp + */ public function getTemplateTimestamp($_template) { // return timestamp @@ -67,13 +67,14 @@ class Smarty_Internal_Resource_Registered { call_user_func_array($this->smarty->_plugins['resource'][$_template->resource_type][0][1], array($_template->resource_name, &$time_stamp, $this->smarty)); return is_numeric($time_stamp) ? (int)$time_stamp : $time_stamp; - } + } + /** - * Get timestamp to template source by type and name - * - * @param object $_template template object - * @return boolean false as string resources have no timestamp - */ + * Get timestamp to template source by type and name + * + * @param object $_template template object + * @return boolean false as string resources have no timestamp + */ public function getTemplateTimestampTypeName($_resource_type, $_resource_name) { // return timestamp @@ -84,11 +85,11 @@ class Smarty_Internal_Resource_Registered { } /** - * Retuen template source from resource name - * - * @param object $_template template object - * @return string content of template source - */ + * Retuen template source from resource name + * + * @param object $_template template object + * @return string content of template source + */ public function getTemplateSource($_template) { // return template string @@ -97,11 +98,11 @@ class Smarty_Internal_Resource_Registered { } /** - * Get filepath to compiled template - * - * @param object $_template template object - * @return boolean return false as compiled template is not stored - */ + * Get filepath to compiled template + * + * @param object $_template template object + * @return boolean return false as compiled template is not stored + */ public function getCompiledFilepath($_template) { $_compile_id = isset($_template->compile_id) ? preg_replace('![^\w\|]+!','_',$_template->compile_id) : null; @@ -134,4 +135,4 @@ class Smarty_Internal_Resource_Registered { } } -?> +?>
\ No newline at end of file diff --git a/libs/sysplugins/smarty_internal_resource_stream.php b/libs/sysplugins/smarty_internal_resource_stream.php index 2024a3a7..de2996e9 100644 --- a/libs/sysplugins/smarty_internal_resource_stream.php +++ b/libs/sysplugins/smarty_internal_resource_stream.php @@ -1,18 +1,18 @@ <?php /** -* Smarty Internal Plugin Resource Stream -* -* Implements the streams as resource for Smarty template -* -* @package Smarty -* @subpackage TemplateResources -* @author Uwe Tews -*/ + * Smarty Internal Plugin Resource Stream + * + * Implements the streams as resource for Smarty template + * + * @package Smarty + * @subpackage TemplateResources + * @author Uwe Tews + */ + /** -* Smarty Internal Plugin Resource Stream -*/ - + * Smarty Internal Plugin Resource Stream + */ class Smarty_Internal_Resource_Stream { public function __construct($smarty) { @@ -27,10 +27,10 @@ class Smarty_Internal_Resource_Stream { public $isEvaluated = true; /** - * Return flag if template source is existing - * - * @return boolean true - */ + * Return flag if template source is existing + * + * @return boolean true + */ public function isExisting($template) { if ($template->getTemplateSource() == '') { @@ -40,11 +40,11 @@ class Smarty_Internal_Resource_Stream { } } /** - * Get filepath to template source - * - * @param object $_template template object - * @return string return 'string' as template source is not a file - */ + * Get filepath to template source + * + * @param object $_template template object + * @return string return 'string' as template source is not a file + */ public function getTemplateFilepath($_template) { // no filepath for strings @@ -53,11 +53,11 @@ class Smarty_Internal_Resource_Stream { } /** - * Get timestamp to template source - * - * @param object $_template template object - * @return boolean false as string resources have no timestamp - */ + * Get timestamp to template source + * + * @param object $_template template object + * @return boolean false as string resources have no timestamp + */ public function getTemplateTimestamp($_template) { // strings must always be compiled and have no timestamp @@ -65,11 +65,11 @@ class Smarty_Internal_Resource_Stream { } /** - * Retuen template source from resource name - * - * @param object $_template template object - * @return string content of template source - */ + * Retuen template source from resource name + * + * @param object $_template template object + * @return string content of template source + */ public function getTemplateSource($_template) { // return template string @@ -84,11 +84,11 @@ class Smarty_Internal_Resource_Stream { } /** - * Get filepath to compiled template - * - * @param object $_template template object - * @return boolean return false as compiled template is not stored - */ + * Get filepath to compiled template + * + * @param object $_template template object + * @return boolean return false as compiled template is not stored + */ public function getCompiledFilepath($_template) { // no filepath for strings @@ -96,4 +96,4 @@ class Smarty_Internal_Resource_Stream { } } -?> +?>
\ No newline at end of file diff --git a/libs/sysplugins/smarty_internal_resource_string.php b/libs/sysplugins/smarty_internal_resource_string.php index ad519b38..f5e28e3c 100644 --- a/libs/sysplugins/smarty_internal_resource_string.php +++ b/libs/sysplugins/smarty_internal_resource_string.php @@ -1,18 +1,18 @@ <?php /** -* Smarty Internal Plugin Resource String -* -* Implements the strings as resource for Smarty template -* -* @package Smarty -* @subpackage TemplateResources -* @author Uwe Tews -*/ + * Smarty Internal Plugin Resource String + * + * Implements the strings as resource for Smarty template + * + * @package Smarty + * @subpackage TemplateResources + * @author Uwe Tews + */ + /** -* Smarty Internal Plugin Resource String -*/ - + * Smarty Internal Plugin Resource String + */ class Smarty_Internal_Resource_String { public function __construct($smarty) { @@ -27,21 +27,21 @@ class Smarty_Internal_Resource_String { public $isEvaluated = true; /** - * Return flag if template source is existing - * - * @return boolean true - */ + * Return flag if template source is existing + * + * @return boolean true + */ public function isExisting($template) { return true; } /** - * Get filepath to template source - * - * @param object $_template template object - * @return string return 'string' as template source is not a file - */ + * Get filepath to template source + * + * @param object $_template template object + * @return string return 'string' as template source is not a file + */ public function getTemplateFilepath($_template) { // no filepath for strings @@ -50,11 +50,11 @@ class Smarty_Internal_Resource_String { } /** - * Get timestamp to template source - * - * @param object $_template template object - * @return boolean false as string resources have no timestamp - */ + * Get timestamp to template source + * + * @param object $_template template object + * @return boolean false as string resources have no timestamp + */ public function getTemplateTimestamp($_template) { // strings must always be compiled and have no timestamp @@ -62,11 +62,11 @@ class Smarty_Internal_Resource_String { } /** - * Retuen template source from resource name - * - * @param object $_template template object - * @return string content of template source - */ + * Retuen template source from resource name + * + * @param object $_template template object + * @return string content of template source + */ public function getTemplateSource($_template) { // return template string @@ -75,11 +75,11 @@ class Smarty_Internal_Resource_String { } /** - * Get filepath to compiled template - * - * @param object $_template template object - * @return boolean return false as compiled template is not stored - */ + * Get filepath to compiled template + * + * @param object $_template template object + * @return boolean return false as compiled template is not stored + */ public function getCompiledFilepath($_template) { // no filepath for strings @@ -87,4 +87,4 @@ class Smarty_Internal_Resource_String { } } -?> +?>
\ No newline at end of file diff --git a/libs/sysplugins/smarty_internal_security_handler.php b/libs/sysplugins/smarty_internal_security_handler.php index 31fe47e5..daf567b2 100644 --- a/libs/sysplugins/smarty_internal_security_handler.php +++ b/libs/sysplugins/smarty_internal_security_handler.php @@ -1,26 +1,27 @@ <?php /** -* Smarty Internal Plugin Security Handler -* -* @package Smarty -* @subpackage Security -* @author Uwe Tews -*/ + * Smarty Internal Plugin Security Handler + * + * @package Smarty + * @subpackage Security + * @author Uwe Tews + */ + /** -* This class contains all methods for security checking -*/ + * This class contains all methods for security checking + */ class Smarty_Internal_Security_Handler { function __construct($smarty) { $this->smarty = $smarty; } /** - * Check if PHP function is trusted. - * - * @param string $function_name - * @param object $compiler compiler object - * @return boolean true if function is trusted - */ + * Check if PHP function is trusted. + * + * @param string $function_name + * @param object $compiler compiler object + * @return boolean true if function is trusted + */ function isTrustedPhpFunction($function_name, $compiler) { if (empty($this->smarty->security_policy->php_functions) || in_array($function_name, $this->smarty->security_policy->php_functions)) { @@ -32,12 +33,12 @@ class Smarty_Internal_Security_Handler { } /** - * Check if static class is trusted. - * - * @param string $class_name - * @param object $compiler compiler object - * @return boolean true if class is trusted - */ + * Check if static class is trusted. + * + * @param string $class_name + * @param object $compiler compiler object + * @return boolean true if class is trusted + */ function isTrustedStaticClass($class_name, $compiler) { if (empty($this->smarty->security_policy->static_classes) || in_array($class_name, $this->smarty->security_policy->static_classes)) { @@ -48,12 +49,12 @@ class Smarty_Internal_Security_Handler { } } /** - * Check if modifier is trusted. - * - * @param string $modifier_name - * @param object $compiler compiler object - * @return boolean true if modifier is trusted - */ + * Check if modifier is trusted. + * + * @param string $modifier_name + * @param object $compiler compiler object + * @return boolean true if modifier is trusted + */ function isTrustedModifier($modifier_name, $compiler) { if (empty($this->smarty->security_policy->modifiers) || in_array($modifier_name, $this->smarty->security_policy->modifiers)) { @@ -64,12 +65,12 @@ class Smarty_Internal_Security_Handler { } } /** - * Check if stream is trusted. - * - * @param string $stream_name - * @param object $compiler compiler object - * @return boolean true if stream is trusted - */ + * Check if stream is trusted. + * + * @param string $stream_name + * @param object $compiler compiler object + * @return boolean true if stream is trusted + */ function isTrustedStream($stream_name) { if (empty($this->smarty->security_policy->streams) || in_array($stream_name, $this->smarty->security_policy->streams)) { @@ -81,12 +82,12 @@ class Smarty_Internal_Security_Handler { } /** - * Check if directory of file resource is trusted. - * - * @param string $filepath - * @param object $compiler compiler object - * @return boolean true if directory is trusted - */ + * Check if directory of file resource is trusted. + * + * @param string $filepath + * @param object $compiler compiler object + * @return boolean true if directory is trusted + */ function isTrustedResourceDir($filepath) { $_rp = realpath($filepath); @@ -115,13 +116,14 @@ class Smarty_Internal_Security_Handler { throw new SmartyException ("directory '{$_rp}' not allowed by security setting"); return false; } + /** - * Check if directory of file resource is trusted. - * - * @param string $filepath - * @param object $compiler compiler object - * @return boolean true if directory is trusted - */ + * Check if directory of file resource is trusted. + * + * @param string $filepath + * @param object $compiler compiler object + * @return boolean true if directory is trusted + */ function isTrustedPHPDir($filepath) { $_rp = realpath($filepath); diff --git a/libs/sysplugins/smarty_internal_smartytemplatecompiler.php b/libs/sysplugins/smarty_internal_smartytemplatecompiler.php index 25e92d96..dcc89c67 100644 --- a/libs/sysplugins/smarty_internal_smartytemplatecompiler.php +++ b/libs/sysplugins/smarty_internal_smartytemplatecompiler.php @@ -9,7 +9,9 @@ * @subpackage Compiler * @author Uwe Tews */ + require_once("smarty_internal_parsetree.php"); + /** * Class SmartyTemplateCompiler */ diff --git a/libs/sysplugins/smarty_internal_template.php b/libs/sysplugins/smarty_internal_template.php index 4786aa4c..bda99e58 100644 --- a/libs/sysplugins/smarty_internal_template.php +++ b/libs/sysplugins/smarty_internal_template.php @@ -376,7 +376,7 @@ class Smarty_Internal_Template extends Smarty_Internal_Data { $this->cacheFileChecked = true; if ($this->caching === SMARTY_CACHING_LIFETIME_SAVED && $this->properties['cache_lifetime'] >= 0 && (time() > ($this->getCachedTimestamp() + $this->properties['cache_lifetime']))) { $this->tpl_vars = array(); - $this->rendered_content = null; + $this->rendered_content = null; return $this->isCached; } if (!empty($this->properties['file_dependency']) && $this->smarty->compile_check) { diff --git a/libs/sysplugins/smarty_internal_templatecompilerbase.php b/libs/sysplugins/smarty_internal_templatecompilerbase.php index c54dd8ab..0a0218c2 100644 --- a/libs/sysplugins/smarty_internal_templatecompilerbase.php +++ b/libs/sysplugins/smarty_internal_templatecompilerbase.php @@ -8,6 +8,7 @@ * @subpackage Compiler
* @author Uwe Tews
*/
+
/**
* Main compiler class
*/
@@ -402,6 +403,5 @@ class Smarty_Internal_TemplateCompilerBase { }
throw new SmartyCompilerException($error_text);
}
-}
-
+}
?>
\ No newline at end of file diff --git a/libs/sysplugins/smarty_internal_templatelexer.php b/libs/sysplugins/smarty_internal_templatelexer.php index 81e5e4b8..dec27404 100644 --- a/libs/sysplugins/smarty_internal_templatelexer.php +++ b/libs/sysplugins/smarty_internal_templatelexer.php @@ -1,15 +1,16 @@ <?php /** -* Smarty Internal Plugin Templatelexer -* -* This is the lexer to break the template source into tokens -* @package Smarty -* @subpackage Compiler -* @author Uwe Tews -*/ + * Smarty Internal Plugin Templatelexer + * + * This is the lexer to break the template source into tokens + * @package Smarty + * @subpackage Compiler + * @author Uwe Tews + */ + /** -* Smarty Internal Plugin Templatelexer -*/ + * Smarty Internal Plugin Templatelexer + */ class Smarty_Internal_Templatelexer { public $data; @@ -22,61 +23,61 @@ class Smarty_Internal_Templatelexer public $state = 1; public $strip = false; private $heredoc_id_stack = Array(); - public $smarty_token_names = array ( // Text for parser error messages - 'IDENTITY' => '===', - 'NONEIDENTITY' => '!==', - 'EQUALS' => '==', - 'NOTEQUALS' => '!=', - 'GREATEREQUAL' => '(>=,ge)', - 'LESSEQUAL' => '(<=,le)', - 'GREATERTHAN' => '(>,gt)', - 'LESSTHAN' => '(<,lt)', - 'MOD' => '(%,mod)', - 'NOT' => '(!,not)', - 'LAND' => '(&&,and)', - 'LOR' => '(||,or)', - 'LXOR' => 'xor', - 'OPENP' => '(', - 'CLOSEP' => ')', - 'OPENB' => '[', - 'CLOSEB' => ']', - 'PTR' => '->', - 'APTR' => '=>', - 'EQUAL' => '=', - 'NUMBER' => 'number', - 'UNIMATH' => '+" , "-', - 'MATH' => '*" , "/" , "%', - 'INCDEC' => '++" , "--', - 'SPACE' => ' ', - 'DOLLAR' => '$', - 'SEMICOLON' => ';', - 'COLON' => ':', - 'DOUBLECOLON' => '::', - 'AT' => '@', - 'HATCH' => '#', - 'QUOTE' => '"', - 'BACKTICK' => '`', - 'VERT' => '|', - 'DOT' => '.', - 'COMMA' => '","', - 'ANDSYM' => '"&"', - 'QMARK' => '"?"', - 'ID' => 'identifier', - 'OTHER' => 'text', - 'LINEBREAK' => 'newline', - 'FAKEPHPSTARTTAG' => 'Fake PHP start tag', - 'PHPSTARTTAG' => 'PHP start tag', - 'PHPENDTAG' => 'PHP end tag', - 'LITERALSTART' => 'Literal start', - 'LITERALEND' => 'Literal end', - 'LDELSLASH' => 'closing tag', - 'COMMENT' => 'comment', - 'LITERALEND' => 'literal close', - 'AS' => 'as', - 'TO' => 'to', - ); - - + public $smarty_token_names = array ( // Text for parser error messages + 'IDENTITY' => '===', + 'NONEIDENTITY' => '!==', + 'EQUALS' => '==', + 'NOTEQUALS' => '!=', + 'GREATEREQUAL' => '(>=,ge)', + 'LESSEQUAL' => '(<=,le)', + 'GREATERTHAN' => '(>,gt)', + 'LESSTHAN' => '(<,lt)', + 'MOD' => '(%,mod)', + 'NOT' => '(!,not)', + 'LAND' => '(&&,and)', + 'LOR' => '(||,or)', + 'LXOR' => 'xor', + 'OPENP' => '(', + 'CLOSEP' => ')', + 'OPENB' => '[', + 'CLOSEB' => ']', + 'PTR' => '->', + 'APTR' => '=>', + 'EQUAL' => '=', + 'NUMBER' => 'number', + 'UNIMATH' => '+" , "-', + 'MATH' => '*" , "/" , "%', + 'INCDEC' => '++" , "--', + 'SPACE' => ' ', + 'DOLLAR' => '$', + 'SEMICOLON' => ';', + 'COLON' => ':', + 'DOUBLECOLON' => '::', + 'AT' => '@', + 'HATCH' => '#', + 'QUOTE' => '"', + 'BACKTICK' => '`', + 'VERT' => '|', + 'DOT' => '.', + 'COMMA' => '","', + 'ANDSYM' => '"&"', + 'QMARK' => '"?"', + 'ID' => 'identifier', + 'OTHER' => 'text', + 'LINEBREAK' => 'newline', + 'FAKEPHPSTARTTAG' => 'Fake PHP start tag', + 'PHPSTARTTAG' => 'PHP start tag', + 'PHPENDTAG' => 'PHP end tag', + 'LITERALSTART' => 'Literal start', + 'LITERALEND' => 'Literal end', + 'LDELSLASH' => 'closing tag', + 'COMMENT' => 'comment', + 'LITERALEND' => 'literal close', + 'AS' => 'as', + 'TO' => 'to', + ); + + function __construct($data,$compiler) { // set instance object @@ -90,8 +91,8 @@ class Smarty_Internal_Templatelexer $this->ldel = preg_quote($this->smarty->left_delimiter,'/'); $this->ldel_length = strlen($this->smarty->left_delimiter); $this->rdel = preg_quote($this->smarty->right_delimiter,'/'); - $this->smarty_token_names['LDEL'] = $this->smarty->left_delimiter; - $this->smarty_token_names['RDEL'] = $this->smarty->right_delimiter; + $this->smarty_token_names['LDEL'] = $this->smarty->left_delimiter; + $this->smarty_token_names['RDEL'] = $this->smarty->right_delimiter; } public static function &instance($new_instance = null) { @@ -1171,4 +1172,4 @@ class Smarty_Internal_Templatelexer } } -?> +?>
\ No newline at end of file diff --git a/libs/sysplugins/smarty_internal_templateparser.php b/libs/sysplugins/smarty_internal_templateparser.php index db18dbb5..750a24b2 100644 --- a/libs/sysplugins/smarty_internal_templateparser.php +++ b/libs/sysplugins/smarty_internal_templateparser.php @@ -1,13 +1,13 @@ <?php
/**
-* Smarty Internal Plugin Templateparser
-*
-* This is the template parser.
-* It is generated from the internal.templateparser.y file
-* @package Smarty
-* @subpackage Compiler
-* @author Uwe Tews
-*/
+ * Smarty Internal Plugin Templateparser
+ *
+ * This is the template parser.
+ * It is generated from the internal.templateparser.y file
+ * @package Smarty
+ * @subpackage Compiler
+ * @author Uwe Tews
+ */
class TP_yyToken implements ArrayAccess
{
@@ -107,12 +107,12 @@ class Smarty_Internal_Templateparser#line 79 "smarty_internal_templateparser.php $this->sec_obj = $this->smarty;
}
$this->compiler->has_variable_string = false;
- $this->compiler->prefix_code = array();
- $this->prefix_number = 0;
- $this->block_nesting_level = 0;
- $this->is_xml = false;
- $this->asp_tags = (ini_get('asp_tags') != '0');
- $this->current_buffer = $this->root_buffer = new _smarty_template_buffer($this);
+ $this->compiler->prefix_code = array();
+ $this->prefix_number = 0;
+ $this->block_nesting_level = 0;
+ $this->is_xml = false;
+ $this->asp_tags = (ini_get('asp_tags') != '0');
+ $this->current_buffer = $this->root_buffer = new _smarty_template_buffer($this);
}
public static function &instance($new_instance = null)
{
@@ -1436,7 +1436,7 @@ static public $yy_action = array( $this->yystack[$this->yyidx]->stateno,
self::$yyRuleInfo[$yyruleno]['lhs']);
if (isset(self::$yyExpectedTokens[$nextstate])) {
- $expected = array_merge($expected, self::$yyExpectedTokens[$nextstate]);
+ $expected = array_merge($expected, self::$yyExpectedTokens[$nextstate]);
if (in_array($token,
self::$yyExpectedTokens[$nextstate], true)) {
$this->yyidx = $yyidx;
@@ -1471,8 +1471,8 @@ static public $yy_action = array( }
break;
} while (true);
- $this->yyidx = $yyidx;
- $this->yystack = $stack;
+ $this->yyidx = $yyidx;
+ $this->yystack = $stack;
return array_unique($expected);
}
@@ -2051,7 +2051,7 @@ static public $yy_action = array( #line 126 "smarty_internal_templateparser.y"
function yy_r6(){
if ($this->sec_obj->php_handling == SMARTY_PHP_PASSTHRU) {
- $this->_retvalue = new _smarty_text($this, self::escape_start_tag($this->yystack[$this->yyidx + 0]->minor));
+ $this->_retvalue = new _smarty_text($this, self::escape_start_tag($this->yystack[$this->yyidx + 0]->minor));
} elseif ($this->sec_obj->php_handling == SMARTY_PHP_QUOTE) {
$this->_retvalue = new _smarty_text($this, htmlspecialchars($this->yystack[$this->yyidx + 0]->minor, ENT_QUOTES));
}elseif ($this->sec_obj->php_handling == SMARTY_PHP_ALLOW) {
@@ -2067,7 +2067,7 @@ static public $yy_action = array( $this->is_xml = true;
$this->_retvalue = new _smarty_text($this, $this->compiler->processNocacheCode("<?php echo '?>';?>", $this->compiler, true));
}elseif ($this->sec_obj->php_handling == SMARTY_PHP_PASSTHRU) {
- $this->_retvalue = new _smarty_text($this, '?<?php ?>>');
+ $this->_retvalue = new _smarty_text($this, '?<?php ?>>');
} elseif ($this->sec_obj->php_handling == SMARTY_PHP_QUOTE) {
$this->_retvalue = new _smarty_text($this, htmlspecialchars('?>', ENT_QUOTES));
}elseif ($this->sec_obj->php_handling == SMARTY_PHP_ALLOW) {
@@ -2080,7 +2080,7 @@ static public $yy_action = array( #line 154 "smarty_internal_templateparser.y"
function yy_r8(){
if ($this->sec_obj->php_handling == SMARTY_PHP_PASSTHRU) {
- $this->_retvalue = new _smarty_text($this, '<<?php ?>%');
+ $this->_retvalue = new _smarty_text($this, '<<?php ?>%');
} elseif ($this->sec_obj->php_handling == SMARTY_PHP_QUOTE) {
$this->_retvalue = new _smarty_text($this, htmlspecialchars($this->yystack[$this->yyidx + 0]->minor, ENT_QUOTES));
}elseif ($this->sec_obj->php_handling == SMARTY_PHP_ALLOW) {
@@ -2101,7 +2101,7 @@ static public $yy_action = array( #line 175 "smarty_internal_templateparser.y"
function yy_r9(){
if ($this->sec_obj->php_handling == SMARTY_PHP_PASSTHRU) {
- $this->_retvalue = new _smarty_text($this, '%<?php ?>>');
+ $this->_retvalue = new _smarty_text($this, '%<?php ?>>');
} elseif ($this->sec_obj->php_handling == SMARTY_PHP_QUOTE) {
$this->_retvalue = new _smarty_text($this, htmlspecialchars('%>', ENT_QUOTES));
}elseif ($this->sec_obj->php_handling == SMARTY_PHP_ALLOW) {
@@ -2121,9 +2121,9 @@ static public $yy_action = array( #line 2117 "smarty_internal_templateparser.php"
#line 195 "smarty_internal_templateparser.y"
function yy_r10(){if ($this->lex->strip) {
- $this->_retvalue = new _smarty_text($this, preg_replace('![\$this->yystack[$this->yyidx + 0]->minor ]*[\r\n]+[\$this->yystack[$this->yyidx + 0]->minor ]*!', '', self::escape_start_tag($this->yystack[$this->yyidx + 0]->minor)));
+ $this->_retvalue = new _smarty_text($this, preg_replace('![\$this->yystack[$this->yyidx + 0]->minor ]*[\r\n]+[\$this->yystack[$this->yyidx + 0]->minor ]*!', '', self::escape_start_tag($this->yystack[$this->yyidx + 0]->minor)));
} else {
- $this->_retvalue = new _smarty_text($this, self::escape_start_tag($this->yystack[$this->yyidx + 0]->minor));
+ $this->_retvalue = new _smarty_text($this, self::escape_start_tag($this->yystack[$this->yyidx + 0]->minor));
}
}
#line 2125 "smarty_internal_templateparser.php"
@@ -2132,9 +2132,9 @@ static public $yy_action = array( #line 2128 "smarty_internal_templateparser.php"
#line 206 "smarty_internal_templateparser.y"
function yy_r12(){if ($this->lex->strip) {
- $this->_retvalue = new _smarty_text($this, preg_replace('![\t ]*[\r\n]+[\t ]*!', '', $this->yystack[$this->yyidx + 0]->minor));
+ $this->_retvalue = new _smarty_text($this, preg_replace('![\t ]*[\r\n]+[\t ]*!', '', $this->yystack[$this->yyidx + 0]->minor));
} else {
- $this->_retvalue = new _smarty_text($this, $this->yystack[$this->yyidx + 0]->minor);
+ $this->_retvalue = new _smarty_text($this, $this->yystack[$this->yyidx + 0]->minor);
}
}
#line 2136 "smarty_internal_templateparser.php"
@@ -2356,9 +2356,9 @@ static public $yy_action = array( #line 2352 "smarty_internal_templateparser.php"
#line 412 "smarty_internal_templateparser.y"
function yy_r107(){if ((!$this->template->security || $this->smarty->security_handler->isTrustedStaticClass($this->yystack[$this->yyidx + -2]->minor, $this->compiler)) || isset($this->smarty->registered_classes[$this->yystack[$this->yyidx + -2]->minor])) {
- if (isset($this->smarty->registered_classes[$this->yystack[$this->yyidx + -2]->minor])) {
+ if (isset($this->smarty->registered_classes[$this->yystack[$this->yyidx + -2]->minor])) {
$this->_retvalue = $this->smarty->registered_classes[$this->yystack[$this->yyidx + -2]->minor].'::'.$this->yystack[$this->yyidx + 0]->minor;
- } else {
+ } else {
$this->_retvalue = $this->yystack[$this->yyidx + -2]->minor.'::'.$this->yystack[$this->yyidx + 0]->minor;
}
} else {
@@ -2466,9 +2466,9 @@ static public $yy_action = array( #line 2462 "smarty_internal_templateparser.php"
#line 514 "smarty_internal_templateparser.y"
function yy_r139(){if (!$this->template->security || $this->smarty->security_handler->isTrustedPhpFunction($this->yystack[$this->yyidx + -3]->minor, $this->compiler)) {
- if ($this->yystack[$this->yyidx + -3]->minor == 'isset' || $this->yystack[$this->yyidx + -3]->minor == 'empty' || $this->yystack[$this->yyidx + -3]->minor == 'array' || is_callable($this->yystack[$this->yyidx + -3]->minor)) {
- $this->_retvalue = $this->yystack[$this->yyidx + -3]->minor . "(". $this->yystack[$this->yyidx + -1]->minor .")";
- } else {
+ if ($this->yystack[$this->yyidx + -3]->minor == 'isset' || $this->yystack[$this->yyidx + -3]->minor == 'empty' || $this->yystack[$this->yyidx + -3]->minor == 'array' || is_callable($this->yystack[$this->yyidx + -3]->minor)) {
+ $this->_retvalue = $this->yystack[$this->yyidx + -3]->minor . "(". $this->yystack[$this->yyidx + -1]->minor .")";
+ } else {
$this->compiler->trigger_template_error ("unknown function \"" . $this->yystack[$this->yyidx + -3]->minor . "\"");
}
} }
diff --git a/libs/sysplugins/smarty_internal_unregister.php b/libs/sysplugins/smarty_internal_unregister.php index c2f57eee..75cb6b05 100644 --- a/libs/sysplugins/smarty_internal_unregister.php +++ b/libs/sysplugins/smarty_internal_unregister.php @@ -1,36 +1,36 @@ <?php /** -* Project: Smarty: the PHP compiling template engine -* File: smarty_internal_unregister.php -* SVN: $Id: $ -* -* This library is free software; you can redistribute it and/or -* modify it under the terms of the GNU Lesser General Public -* License as published by the Free Software Foundation; either -* version 2.1 of the License, or (at your option) any later version. -* -* This library is distributed in the hope that it will be useful, -* but WITHOUT ANY WARRANTY; without even the implied warranty of -* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -* Lesser General Public License for more details. -* -* You should have received a copy of the GNU Lesser General Public -* License along with this library; if not, write to the Free Software -* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA -* -* For questions, help, comments, discussion, etc., please join the -* Smarty mailing list. Send a blank e-mail to -* smarty-discussion-subscribe@googlegroups.com -* -* @link http://www.smarty.net/ -* @copyright 2008 New Digital Group, Inc. -* @author Monte Ohrt <monte at ohrt dot com> -* @author Uwe Tews -* @package Smarty -* @subpackage PluginsInternal -* @version 3-SVN$Rev: 3286 $ -*/ + * Project: Smarty: the PHP compiling template engine + * File: smarty_internal_unregister.php + * SVN: $Id: $ + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Lesser General Public + * License as published by the Free Software Foundation; either + * version 2.1 of the License, or (at your option) any later version. + * + * This library is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public + * License along with this library; if not, write to the Free Software + * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA + * + * For questions, help, comments, discussion, etc., please join the + * Smarty mailing list. Send a blank e-mail to + * smarty-discussion-subscribe@googlegroups.com + * + * @link http://www.smarty.net/ + * @copyright 2008 New Digital Group, Inc. + * @author Monte Ohrt <monte at ohrt dot com> + * @author Uwe Tews + * @package Smarty + * @subpackage PluginsInternal + * @version 3-SVN$Rev: 3286 $ + */ class Smarty_Internal_Unregister { @@ -41,10 +41,10 @@ class Smarty_Internal_Unregister { } /** - * Unregisters block function - * - * @param string $block_tag name of template function - */ + * Unregisters block function + * + * @param string $block_tag name of template function + */ function block($block_tag) { if (isset($this->smarty->registered_plugins['block'][$block_tag])) { @@ -53,10 +53,10 @@ class Smarty_Internal_Unregister { } /** - * Unregisters compiler function - * - * @param string $compiler_tag name of template function - */ + * Unregisters compiler function + * + * @param string $compiler_tag name of template function + */ function compilerFunction($compiler_tag) { if (isset($this->smarty->registered_plugins['compiler'][$compiler_tag])) { @@ -65,10 +65,10 @@ class Smarty_Internal_Unregister { } /** - * Unregisters custom function - * - * @param string $function_tag name of template function - */ + * Unregisters custom function + * + * @param string $function_tag name of template function + */ function templateFunction($function_tag) { if (isset($this->smarty->registered_plugins['function'][$function_tag])) { @@ -77,10 +77,10 @@ class Smarty_Internal_Unregister { } /** - * Unregisters modifier - * - * @param string $modifier name of template modifier - */ + * Unregisters modifier + * + * @param string $modifier name of template modifier + */ function modifier($modifier) { if (isset($this->smarty->registered_plugins['modifier'][$modifier])) { @@ -89,73 +89,74 @@ class Smarty_Internal_Unregister { } /** - * Unregisters template object - * - * @param string $object_name name of template object - */ + * Unregisters template object + * + * @param string $object_name name of template object + */ function templateObject($object_name) { unset($this->smarty->registered_objects[$object_name]); } /** - * Unregisters template class - * - * @param string $object_name name of template object - */ + * Unregisters template class + * + * @param string $object_name name of template object + */ function templateClass($class_name) { unset($this->smarty->registered_classes[$class_name]); } /** - * Unregisters an output filter - * - * @param callback $function_name - */ + * Unregisters an output filter + * + * @param callback $function_name + */ function outputFilter($function_name) { unset($this->smarty->registered_filters['output'][$this->smarty->_get_filter_name($function_name)]); } /** - * Unregisters a postfilter function - * - * @param callback $function_name - */ + * Unregisters a postfilter function + * + * @param callback $function_name + */ function postFilter($function_name) { unset($this->smarty->registered_filters['post'][$this->smarty->_get_filter_name($function_name)]); } /** - * Unregisters a prefilter function - * - * @param callback $function_name - */ + * Unregisters a prefilter function + * + * @param callback $function_name + */ function preFilter($function_name) { unset($this->smarty->registered_filters['pre'][$this->smarty->_get_filter_name($function_name)]); } /** - * Unregisters a resource - * - * @param string $resource_name name of resource - */ + * Unregisters a resource + * + * @param string $resource_name name of resource + */ function resource($resource_name) { unset($this->smarty->plugins['resource'][$resource_name]); } /** - * Unregisters a variablefilter function - * - * @param callback $function_name - */ + * Unregisters a variablefilter function + * + * @param callback $function_name + */ function variableFilter($function_name) { unset($this->smarty->registered_filters['variable'][$this->smarty->_get_filter_name($function_name)]); } } +?>
\ No newline at end of file diff --git a/libs/sysplugins/smarty_internal_utility.php b/libs/sysplugins/smarty_internal_utility.php index 83e62c60..e3cb6cec 100644 --- a/libs/sysplugins/smarty_internal_utility.php +++ b/libs/sysplugins/smarty_internal_utility.php @@ -274,3 +274,4 @@ class Smarty_Internal_Utility { return true; } } +?>
\ No newline at end of file diff --git a/libs/sysplugins/smarty_internal_wrapper.php b/libs/sysplugins/smarty_internal_wrapper.php index be6f4063..6301f92f 100644 --- a/libs/sysplugins/smarty_internal_wrapper.php +++ b/libs/sysplugins/smarty_internal_wrapper.php @@ -1,36 +1,36 @@ <?php /** -* Project: Smarty: the PHP compiling template engine -* File: smarty_internal_wrapper.php -* SVN: $Id: $ -* -* This library is free software; you can redistribute it and/or -* modify it under the terms of the GNU Lesser General Public -* License as published by the Free Software Foundation; either -* version 2.1 of the License, or (at your option) any later version. -* -* This library is distributed in the hope that it will be useful, -* but WITHOUT ANY WARRANTY; without even the implied warranty of -* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -* Lesser General Public License for more details. -* -* You should have received a copy of the GNU Lesser General Public -* License along with this library; if not, write to the Free Software -* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA -* -* For questions, help, comments, discussion, etc., please join the -* Smarty mailing list. Send a blank e-mail to -* smarty-discussion-subscribe@googlegroups.com -* -* @link http://www.smarty.net/ -* @copyright 2008 New Digital Group, Inc. -* @author Monte Ohrt <monte at ohrt dot com> -* @author Uwe Tews -* @package Smarty -* @subpackage PluginsInternal -* @version 3-SVN$Rev: 3286 $ -*/ + * Project: Smarty: the PHP compiling template engine + * File: smarty_internal_wrapper.php + * SVN: $Id: $ + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Lesser General Public + * License as published by the Free Software Foundation; either + * version 2.1 of the License, or (at your option) any later version. + * + * This library is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public + * License along with this library; if not, write to the Free Software + * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA + * + * For questions, help, comments, discussion, etc., please join the + * Smarty mailing list. Send a blank e-mail to + * smarty-discussion-subscribe@googlegroups.com + * + * @link http://www.smarty.net/ + * @copyright 2008 New Digital Group, Inc. + * @author Monte Ohrt <monte at ohrt dot com> + * @author Uwe Tews + * @package Smarty + * @subpackage PluginsInternal + * @version 3-SVN$Rev: 3286 $ + */ /* * Smarty Backward Compatability Wrapper @@ -45,12 +45,12 @@ class Smarty_Internal_Wrapper { } /** - * Converts smarty2-style function call to smarty 3-style function call - * This is expensive, be sure to port your code to Smarty 3! - * - * @param string $name Smarty 2 function name - * @param array $args Smarty 2 function args - */ + * Converts smarty2-style function call to smarty 3-style function call + * This is expensive, be sure to port your code to Smarty 3! + * + * @param string $name Smarty 2 function name + * @param array $args Smarty 2 function args + */ function convert($name, $args) { // throw notice about deprecated function if($this->smarty->deprecation_notices) @@ -124,4 +124,4 @@ class Smarty_Internal_Wrapper { } } -?> +?>
\ No newline at end of file diff --git a/libs/sysplugins/smarty_internal_write_file.php b/libs/sysplugins/smarty_internal_write_file.php index a520a94d..6ec5e2df 100644 --- a/libs/sysplugins/smarty_internal_write_file.php +++ b/libs/sysplugins/smarty_internal_write_file.php @@ -1,23 +1,24 @@ <?php /** -* Smarty write file plugin -* -* @package Smarty -* @subpackage PluginsInternal -* @author Monte Ohrt -*/ + * Smarty write file plugin + * + * @package Smarty + * @subpackage PluginsInternal + * @author Monte Ohrt + */ + /** -* Smarty Internal Write File Class -*/ + * Smarty Internal Write File Class + */ class Smarty_Internal_Write_File { /** - * Writes file in a save way to disk - * - * @param string $_filepath complete filepath - * @param string $_contents file content - * @return boolean true - */ + * Writes file in a save way to disk + * + * @param string $_filepath complete filepath + * @param string $_contents file content + * @return boolean true + */ public static function writeFile($_filepath, $_contents, $smarty) { $old_umask = umask(0); diff --git a/libs/sysplugins/smarty_security.php b/libs/sysplugins/smarty_security.php index 9fb85a9f..0a0a0bb9 100644 --- a/libs/sysplugins/smarty_security.php +++ b/libs/sysplugins/smarty_security.php @@ -1,96 +1,96 @@ <?php /** -* Smarty plugin -* -* @package Smarty -* @subpackage Security -* @author Uwe Tews -*/ + * Smarty plugin + * + * @package Smarty + * @subpackage Security + * @author Uwe Tews + */ /** -* This class does contain the security settings -*/ + * This class does contain the security settings + */ class Smarty_Security { /** - * This determines how Smarty handles "<?php ... ?>" tags in templates. - * possible values: - * <ul> - * <li>SMARTY_PHP_PASSTHRU -> echo PHP tags as they are</li> - * <li>SMARTY_PHP_QUOTE -> escape tags as entities</li> - * <li>SMARTY_PHP_REMOVE -> remove php tags</li> - * <li>SMARTY_PHP_ALLOW -> execute php tags</li> - * </ul> - * - * @var integer - */ + * This determines how Smarty handles "<?php ... ?>" tags in templates. + * possible values: + * <ul> + * <li>SMARTY_PHP_PASSTHRU -> echo PHP tags as they are</li> + * <li>SMARTY_PHP_QUOTE -> escape tags as entities</li> + * <li>SMARTY_PHP_REMOVE -> remove php tags</li> + * <li>SMARTY_PHP_ALLOW -> execute php tags</li> + * </ul> + * + * @var integer + */ public $php_handling = SMARTY_PHP_PASSTHRU; /** - * This is the list of template directories that are considered secure. - * One directory per array element. - * $template_dir is in this list implicitly. - * - * @var array - */ + * This is the list of template directories that are considered secure. + * One directory per array element. + * $template_dir is in this list implicitly. + * + * @var array + */ public $secure_dir = array(); /** - * This is an array of directories where trusted php scripts reside. - * {@link $security} is disabled during their inclusion/execution. - * - * @var array - */ + * This is an array of directories where trusted php scripts reside. + * {@link $security} is disabled during their inclusion/execution. + * + * @var array + */ public $trusted_dir = array(); /** - * This is an array of trusted static classes. - * - * If empty access to all static classes is allowed. - * If set to 'none' none is allowed. - * @var array - */ + * This is an array of trusted static classes. + * + * If empty access to all static classes is allowed. + * If set to 'none' none is allowed. + * @var array + */ public $static_classes = array(); /** - * This is an array of trusted PHP functions. - * - * If empty all functions are allowed. - * If set to 'none' none is allowed. - * @var array - */ + * This is an array of trusted PHP functions. + * + * If empty all functions are allowed. + * If set to 'none' none is allowed. + * @var array + */ public $php_functions = array('isset', 'empty', 'count', 'sizeof','in_array', 'is_array','time','nl2br'); /** - * This is an array of trusted modifers. - * - * If empty all modifiers are allowed. - * If set to 'none' none is allowed. - * @var array - */ + * This is an array of trusted modifers. + * + * If empty all modifiers are allowed. + * If set to 'none' none is allowed. + * @var array + */ public $modifiers = array('escape','count'); /** - * This is an array of trusted streams. - * - * If empty all streams are allowed. - * If set to 'none' none is allowed. - * @var array - */ + * This is an array of trusted streams. + * + * If empty all streams are allowed. + * If set to 'none' none is allowed. + * @var array + */ public $streams = array('file'); /** - + flag if constants can be accessed from template - */ + * + flag if constants can be accessed from template + */ public $allow_constants = true; /** - + flag if super globals can be accessed from template - */ + * + flag if super globals can be accessed from template + */ public $allow_super_globals = true; /** - + flag if {php} tag can be executed - */ + * + flag if {php} tag can be executed + */ public $allow_php_tag = false; } |
