cvs: smarty /libs Smarty_Compiler.class.php

[email protected] ("Danilo Buerger") Tue, 27 Feb 2007 11:14:10 -0000
Newsgroups php.smarty.cvs
Message-ID <cvsdanilo1172574850@cvsserver>
danilo		Tue Feb 27 11:14:10 2007 UTC

  Modified files:              
    /smarty/libs	Smarty_Compiler.class.php 
  Log:
  Modified _(push|pop)_cacheable_state() to embedd alternate syntax. See this bug report: http://www.phpinsider.com/smarty-forum/viewtopic.php?t=10502
  
  
  
http://cvs.php.net/viewvc.cgi/smarty/libs/Smarty_Compiler.class.php?r1=1.392&r2=1.393&diff_format=u
Index: smarty/libs/Smarty_Compiler.class.php
diff -u smarty/libs/Smarty_Compiler.class.php:1.392 smarty/libs/Smarty_Compiler.class.php:1.393
--- smarty/libs/Smarty_Compiler.class.php:1.392	Fri Feb 23 19:40:01 2007
+++ smarty/libs/Smarty_Compiler.class.php	Tue Feb 27 11:14:10 2007
@@ -26,7 +26,7 @@
  * @package Smarty
  */
 
-/* $Id: Smarty_Compiler.class.php,v 1.392 2007/02/23 19:40:01 mohrt Exp $ */
+/* $Id: Smarty_Compiler.class.php,v 1.393 2007/02/27 11:14:10 danilo Exp $ */
 
 /**
  * Template compiling class
@@ -2238,9 +2238,9 @@
         if ($_cacheable
             || 0<$this->_cacheable_state++) return '';
         if (!isset($this->_cache_serial)) $this->_cache_serial = md5(uniqid('Smarty'));
-        $_ret = 'if ($this->caching && !$this->_cache_including) { echo \'{nocache:'
+        $_ret = 'if ($this->caching && !$this->_cache_including): echo \'{nocache:'
             . $this->_cache_serial . '#' . $this->_nocache_count
-            . '}\'; };';
+            . '}\'; endif;';
         return $_ret;
     }
 
@@ -2255,9 +2255,9 @@
         $_cacheable = !isset($this->_plugins[$type][$name]) || $this->_plugins[$type][$name][4];
         if ($_cacheable
             || --$this->_cacheable_state>0) return '';
-        return 'if ($this->caching && !$this->_cache_including) { echo \'{/nocache:'
+        return 'if ($this->caching && !$this->_cache_including): echo \'{/nocache:'
             . $this->_cache_serial . '#' . ($this->_nocache_count++)
-            . '}\'; };';
+            . '}\'; endif;';
     }