]> git.andy128k.dev Git - ipf-template.git/commitdiff
Shortcuts: {openbrace} == {literal}{{/literal}, {closebrace} == {literal}}{/literal}.
authorAndrey Kutejko <andy128k@gmail.com>
Sun, 6 Oct 2013 15:58:13 +0000 (18:58 +0300)
committerAndrey Kutejko <andy128k@gmail.com>
Sun, 6 Oct 2013 15:58:13 +0000 (18:58 +0300)
lib/compiler.php

index 654e7e7a3bb12ce86ac141dcbe27b372b547065e..47dac3cd8047654b707416d30bae8e006718026a 100644 (file)
@@ -294,6 +294,12 @@ class IPF_Template_Compiler
         case '/literal':
             trigger_error('Start tag of a block missing: literal', E_USER_ERROR);
             break;
+        case 'openbrace':
+            $res = '?>{<?php ';
+            break;
+        case 'closebrace':
+            $res = '?>}<?php ';
+            break;
         case 'block':
             if (isset($this->_extendBlocks[$args]))
                 $res = '?>'.$this->_extendBlocks[$args].'<?php ';