From 9d8f7d6cd2b0fd691c640473e524a2902c211e69 Mon Sep 17 00:00:00 2001 From: xue <> Date: Sat, 31 Mar 2007 13:43:49 +0000 Subject: Fixed localize string escaping issue. --- framework/Web/UI/TTemplateManager.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'framework') diff --git a/framework/Web/UI/TTemplateManager.php b/framework/Web/UI/TTemplateManager.php index cfe4f4d4..6bc3ae59 100644 --- a/framework/Web/UI/TTemplateManager.php +++ b/framework/Web/UI/TTemplateManager.php @@ -620,7 +620,7 @@ class TTemplate extends TApplicationComponent implements ITemplate $tpl[$c++]=array($container,array(TCompositeLiteral::TYPE_EXPRESSION,"\$this->publishFilePath('$this->_contextPath/$literal')")); else if($str[2]==='[') { - $literal=trim(substr($literal,0,strlen($literal)-1)); + $literal=strtr(trim(substr($literal,0,strlen($literal)-1)),array("'"=>"\'","\\"=>"\\\\")); $tpl[$c++]=array($container,array(TCompositeLiteral::TYPE_EXPRESSION,"Prado::localize('$literal')")); } } -- cgit v1.2.3