From 28e7c4ba90fe44ed81a1f2626b0f363bf4882c95 Mon Sep 17 00:00:00 2001 From: jerome Date: Fri, 21 Mar 2014 20:23:47 +0100 Subject: [PATCH] Change to prevent javascript single line object definition to be removed by template.Display(). --- src/psm/Service/Template.class.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/psm/Service/Template.class.php b/src/psm/Service/Template.class.php index 86d51e45..7fe9c6f1 100755 --- a/src/psm/Service/Template.class.php +++ b/src/psm/Service/Template.class.php @@ -154,7 +154,7 @@ class Template { $result = preg_replace('{(.*?)}is', '', $this->templates[$id]); // check for tpl variables that have not been replaced. ie: {name}. ignore literal stuff, though. ie: {{name}} is {name} and should not be removed - preg_match_all('~{?{(.+?)}}?~', $result, $matches); + preg_match_all('~{?{(\w+?)}}?~', $result, $matches); foreach($matches[0] as $match) { if (substr($match, 0, 2) == '{{') {