diff --git a/change_log.txt b/change_log.txt index 2581f7d4..db830696 100644 --- a/change_log.txt +++ b/change_log.txt @@ -1,5 +1,7 @@ 01/06/2010 - bugfix on template functions used with template inheritance +- removed /* vim: set expandtab: */ comments +- bugfix of auto literal problem introduce with fix of 31/05/2010 31/05/2010 - bugfix the parser did not allow some smarty variables with special name like $for, $if, $else and others. diff --git a/libs/plugins/function.counter.php b/libs/plugins/function.counter.php index 24959cd6..1f6e1cf7 100644 --- a/libs/plugins/function.counter.php +++ b/libs/plugins/function.counter.php @@ -74,7 +74,4 @@ function smarty_function_counter($params, $smarty) return $retval; } - -/* vim: set expandtab: */ - ?> \ No newline at end of file diff --git a/libs/plugins/function.cycle.php b/libs/plugins/function.cycle.php index 65f1d5b2..509584c9 100644 --- a/libs/plugins/function.cycle.php +++ b/libs/plugins/function.cycle.php @@ -100,7 +100,4 @@ function smarty_function_cycle($params, $smarty) return $retval; } - -/* vim: set expandtab: */ - ?> \ No newline at end of file diff --git a/libs/plugins/function.popup_init.php b/libs/plugins/function.popup_init.php index ae580376..dc5bbd7a 100644 --- a/libs/plugins/function.popup_init.php +++ b/libs/plugins/function.popup_init.php @@ -35,7 +35,4 @@ function smarty_function_popup_init($params, $smarty, $template) trigger_error("popup_init: missing src parameter",E_USER_WARNING); } } - -/* vim: set expandtab: */ - -?> +?> \ No newline at end of file diff --git a/libs/plugins/modifier.regex_replace.php b/libs/plugins/modifier.regex_replace.php index 100b58ce..7c6e6b90 100644 --- a/libs/plugins/modifier.regex_replace.php +++ b/libs/plugins/modifier.regex_replace.php @@ -42,7 +42,4 @@ function _smarty_regex_replace_check($search) } return $search; } - -/* vim: set expandtab: */ - -?> +?> \ 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 f7142f91..5bd21ef8 100644 --- a/libs/plugins/shared.escape_special_chars.php +++ b/libs/plugins/shared.escape_special_chars.php @@ -25,7 +25,4 @@ function smarty_function_escape_special_chars($string) } return $string; } - -/* vim: set expandtab: */ - -?> +?> \ No newline at end of file diff --git a/libs/sysplugins/smarty_internal_templatelexer.php b/libs/sysplugins/smarty_internal_templatelexer.php index bbf3c749..1a946663 100644 --- a/libs/sysplugins/smarty_internal_templatelexer.php +++ b/libs/sysplugins/smarty_internal_templatelexer.php @@ -270,7 +270,7 @@ class Smarty_Internal_Templatelexer function yy_r1_11($yy_subpatterns) { - if ($this->smarty->auto_literal && substr($this->value,$this->ldel_length,1) == ' ') { + if ($this->smarty->auto_literal && trim(substr($this->value,$this->ldel_length,1)) == '') { $this->token = Smarty_Internal_Templateparser::TP_OTHER; } else { $this->token = Smarty_Internal_Templateparser::TP_LDELIF; @@ -281,7 +281,7 @@ class Smarty_Internal_Templatelexer function yy_r1_13($yy_subpatterns) { - if ($this->smarty->auto_literal && substr($this->value,$this->ldel_length,1) == ' ') { + if ($this->smarty->auto_literal && trim(substr($this->value,$this->ldel_length,1)) == '') { $this->token = Smarty_Internal_Templateparser::TP_OTHER; } else { $this->token = Smarty_Internal_Templateparser::TP_LDELFOR; @@ -292,7 +292,7 @@ class Smarty_Internal_Templatelexer function yy_r1_14($yy_subpatterns) { - if ($this->smarty->auto_literal && substr($this->value,$this->ldel_length,1) == ' ') { + if ($this->smarty->auto_literal && trim(substr($this->value,$this->ldel_length,1)) == '') { $this->token = Smarty_Internal_Templateparser::TP_OTHER; } else { $this->token = Smarty_Internal_Templateparser::TP_LDELFOREACH; @@ -479,7 +479,7 @@ class Smarty_Internal_Templatelexer function yy_r2_3($yy_subpatterns) { - if ($this->smarty->auto_literal && substr($this->value,$this->ldel_length,1) == ' ') { + if ($this->smarty->auto_literal && trim(substr($this->value,$this->ldel_length,1)) == '') { $this->token = Smarty_Internal_Templateparser::TP_OTHER; } else { $this->token = Smarty_Internal_Templateparser::TP_LDELIF; @@ -490,7 +490,7 @@ class Smarty_Internal_Templatelexer function yy_r2_5($yy_subpatterns) { - if ($this->smarty->auto_literal && substr($this->value,$this->ldel_length,1) == ' ') { + if ($this->smarty->auto_literal && trim(substr($this->value,$this->ldel_length,1)) == '') { $this->token = Smarty_Internal_Templateparser::TP_OTHER; } else { $this->token = Smarty_Internal_Templateparser::TP_LDELFOR; @@ -501,7 +501,7 @@ class Smarty_Internal_Templatelexer function yy_r2_6($yy_subpatterns) { - if ($this->smarty->auto_literal && substr($this->value,$this->ldel_length,1) == ' ') { + if ($this->smarty->auto_literal && trim(substr($this->value,$this->ldel_length,1)) == '') { $this->token = Smarty_Internal_Templateparser::TP_OTHER; } else { $this->token = Smarty_Internal_Templateparser::TP_LDELFOREACH; @@ -1021,7 +1021,7 @@ class Smarty_Internal_Templatelexer function yy_r4_2($yy_subpatterns) { - if ($this->smarty->auto_literal && substr($this->value,$this->ldel_length,1) == ' ') { + if ($this->smarty->auto_literal && trim(substr($this->value,$this->ldel_length,1)) == '') { $this->token = Smarty_Internal_Templateparser::TP_OTHER; } else { $this->token = Smarty_Internal_Templateparser::TP_LDELIF; @@ -1032,7 +1032,7 @@ class Smarty_Internal_Templatelexer function yy_r4_4($yy_subpatterns) { - if ($this->smarty->auto_literal && substr($this->value,$this->ldel_length,1) == ' ') { + if ($this->smarty->auto_literal && trim(substr($this->value,$this->ldel_length,1)) == '') { $this->token = Smarty_Internal_Templateparser::TP_OTHER; } else { $this->token = Smarty_Internal_Templateparser::TP_LDELFOR; @@ -1043,7 +1043,7 @@ class Smarty_Internal_Templatelexer function yy_r4_5($yy_subpatterns) { - if ($this->smarty->auto_literal && substr($this->value,$this->ldel_length,1) == ' ') { + if ($this->smarty->auto_literal && trim(substr($this->value,$this->ldel_length,1)) == '') { $this->token = Smarty_Internal_Templateparser::TP_OTHER; } else { $this->token = Smarty_Internal_Templateparser::TP_LDELFOREACH;