Files
smarty/libs/sysplugins/smarty_internal_compile_ldelim.php

41 lines
1.1 KiB
PHP
Raw Normal View History

<?php
/**
2010-08-17 15:39:51 +00:00
* Smarty Internal Plugin Compile Ldelim
2011-09-16 14:19:56 +00:00
* Compiles the {ldelim} tag
*
* @package Smarty
2010-08-17 15:39:51 +00:00
* @subpackage Compiler
* @author Uwe Tews
2010-08-17 15:39:51 +00:00
*/
/**
2010-08-17 15:39:51 +00:00
* Smarty Internal Plugin Compile Ldelim Class
2011-09-16 14:19:56 +00:00
*
* @package Smarty
2011-09-16 14:19:56 +00:00
* @subpackage Compiler
*/
class Smarty_Internal_Compile_Ldelim extends Smarty_Internal_CompileBase
{
/**
2010-08-17 15:39:51 +00:00
* Compiles code for the {ldelim} tag
2011-09-16 14:19:56 +00:00
* This tag does output the left delimiter
*
* @param array $args array with attributes from parser
* @param \Smarty_Internal_TemplateCompilerBase $compiler compiler object
*
2010-08-17 15:39:51 +00:00
* @return string compiled code
* @throws \SmartyCompilerException
2010-08-17 15:39:51 +00:00
*/
public function compile($args, Smarty_Internal_TemplateCompilerBase $compiler)
{
2011-09-16 14:19:56 +00:00
$_attr = $this->getAttributes($compiler, $args);
2016-02-09 01:27:15 +01:00
if ($_attr[ 'nocache' ] === true) {
$compiler->trigger_template_error('nocache option not allowed', null, true);
}
// this tag does not return compiled code
2011-09-16 14:19:56 +00:00
$compiler->has_code = true;
2011-09-16 14:19:56 +00:00
return $compiler->smarty->left_delimiter;
}
2010-08-17 15:39:51 +00:00
}