This commit is contained in:
Uwe.Tews
2009-11-26 21:08:45 +00:00
parent 4afab27bd8
commit f3f01b928a
2 changed files with 12 additions and 9 deletions

View File

@@ -1,3 +1,6 @@
11/26/2009
- bugfix on nested doublequoted strings
11/25/2009
- allow the following writing for boolean: true, TRUE, True, false, FALSE, False
- {strip} tag functionality rewritten

View File

@@ -1253,7 +1253,7 @@ class Smarty_Internal_Templatelexer
if ($this->counter >= strlen($this->data)) {
return false; // end of input
}
$yy_global_pattern = "/^(".$this->ldel."\\s{1,}\/)|^(".$this->ldel."\\s{1,})|^(".$this->ldel."\/)|^(".$this->ldel.")|^(\")|^(`\\$)|^(\\$\\w+)|^(\\$)|^(([\S\s]*?)(\\\\\\\\|[^\\\\]\"|".$this->ldel."|\\$|`\\$))|^([\S\s]+)/";
$yy_global_pattern = "/^(".$this->ldel."\\s{1,}\/)|^(".$this->ldel."\\s{1,})|^(".$this->ldel."\/)|^(".$this->ldel.")|^(\")|^(`\\$)|^(\\$\\w+)|^(\\$)|^(([\S\s]*?)(".$this->ldel."|\\$|`\\$|\\\\\\\\|[^\\\\]\"))|^([\S\s]+)/";
do {
if (preg_match($yy_global_pattern, substr($this->data, $this->counter), $yymatches)) {
@@ -1293,14 +1293,14 @@ class Smarty_Internal_Templatelexer
// skip this token
continue;
} else { $yy_yymore_patterns = array(
1 => array(0, "^(".$this->ldel."\\s{1,})|^(".$this->ldel."\/)|^(".$this->ldel.")|^(\")|^(`\\$)|^(\\$\\w+)|^(\\$)|^(([\S\s]*?)(\\\\\\\\|[^\\\\]\"|".$this->ldel."|\\$|`\\$))|^([\S\s]+)"),
2 => array(0, "^(".$this->ldel."\/)|^(".$this->ldel.")|^(\")|^(`\\$)|^(\\$\\w+)|^(\\$)|^(([\S\s]*?)(\\\\\\\\|[^\\\\]\"|".$this->ldel."|\\$|`\\$))|^([\S\s]+)"),
3 => array(0, "^(".$this->ldel.")|^(\")|^(`\\$)|^(\\$\\w+)|^(\\$)|^(([\S\s]*?)(\\\\\\\\|[^\\\\]\"|".$this->ldel."|\\$|`\\$))|^([\S\s]+)"),
4 => array(0, "^(\")|^(`\\$)|^(\\$\\w+)|^(\\$)|^(([\S\s]*?)(\\\\\\\\|[^\\\\]\"|".$this->ldel."|\\$|`\\$))|^([\S\s]+)"),
5 => array(0, "^(`\\$)|^(\\$\\w+)|^(\\$)|^(([\S\s]*?)(\\\\\\\\|[^\\\\]\"|".$this->ldel."|\\$|`\\$))|^([\S\s]+)"),
6 => array(0, "^(\\$\\w+)|^(\\$)|^(([\S\s]*?)(\\\\\\\\|[^\\\\]\"|".$this->ldel."|\\$|`\\$))|^([\S\s]+)"),
7 => array(0, "^(\\$)|^(([\S\s]*?)(\\\\\\\\|[^\\\\]\"|".$this->ldel."|\\$|`\\$))|^([\S\s]+)"),
8 => array(0, "^(([\S\s]*?)(\\\\\\\\|[^\\\\]\"|".$this->ldel."|\\$|`\\$))|^([\S\s]+)"),
1 => array(0, "^(".$this->ldel."\\s{1,})|^(".$this->ldel."\/)|^(".$this->ldel.")|^(\")|^(`\\$)|^(\\$\\w+)|^(\\$)|^(([\S\s]*?)(".$this->ldel."|\\$|`\\$|\\\\\\\\|[^\\\\]\"))|^([\S\s]+)"),
2 => array(0, "^(".$this->ldel."\/)|^(".$this->ldel.")|^(\")|^(`\\$)|^(\\$\\w+)|^(\\$)|^(([\S\s]*?)(".$this->ldel."|\\$|`\\$|\\\\\\\\|[^\\\\]\"))|^([\S\s]+)"),
3 => array(0, "^(".$this->ldel.")|^(\")|^(`\\$)|^(\\$\\w+)|^(\\$)|^(([\S\s]*?)(".$this->ldel."|\\$|`\\$|\\\\\\\\|[^\\\\]\"))|^([\S\s]+)"),
4 => array(0, "^(\")|^(`\\$)|^(\\$\\w+)|^(\\$)|^(([\S\s]*?)(".$this->ldel."|\\$|`\\$|\\\\\\\\|[^\\\\]\"))|^([\S\s]+)"),
5 => array(0, "^(`\\$)|^(\\$\\w+)|^(\\$)|^(([\S\s]*?)(".$this->ldel."|\\$|`\\$|\\\\\\\\|[^\\\\]\"))|^([\S\s]+)"),
6 => array(0, "^(\\$\\w+)|^(\\$)|^(([\S\s]*?)(".$this->ldel."|\\$|`\\$|\\\\\\\\|[^\\\\]\"))|^([\S\s]+)"),
7 => array(0, "^(\\$)|^(([\S\s]*?)(".$this->ldel."|\\$|`\\$|\\\\\\\\|[^\\\\]\"))|^([\S\s]+)"),
8 => array(0, "^(([\S\s]*?)(".$this->ldel."|\\$|`\\$|\\\\\\\\|[^\\\\]\"))|^([\S\s]+)"),
9 => array(2, "^([\S\s]+)"),
12 => array(2, ""),
);