diff options
| author | Uwe.Tews <uwe.tews@localhost> | 2010-01-14 20:57:27 +0000 |
|---|---|---|
| committer | Uwe.Tews <uwe.tews@localhost> | 2010-01-14 20:57:27 +0000 |
| commit | 383e4bb4ae639ed8f47c582dd20d9be1414af610 (patch) | |
| tree | 89a5d77f4298b2bd0c5ba2c5050527c2a9fec5b6 /libs/sysplugins/smarty_internal_compile_if.php | |
| parent | 13444e9781d839b7ff965bec9caab9a1ac421849 (diff) | |
| download | smarty-383e4bb4ae639ed8f47c582dd20d9be1414af610.tar.gz smarty-383e4bb4ae639ed8f47c582dd20d9be1414af610.tar.bz2 smarty-383e4bb4ae639ed8f47c582dd20d9be1414af610.zip | |
- revert handling of newline on no output tags like {if...}
Diffstat (limited to 'libs/sysplugins/smarty_internal_compile_if.php')
| -rw-r--r-- | libs/sysplugins/smarty_internal_compile_if.php | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/libs/sysplugins/smarty_internal_compile_if.php b/libs/sysplugins/smarty_internal_compile_if.php index d3fa9881..9d05f424 100644 --- a/libs/sysplugins/smarty_internal_compile_if.php +++ b/libs/sysplugins/smarty_internal_compile_if.php @@ -31,7 +31,7 @@ class Smarty_Internal_Compile_If extends Smarty_Internal_CompileBase { $_output .= "if (\$_smarty_tpl->tpl_vars[".$args['if condition']['var']."]->value = ".$args['if condition']['value']."){?>"; return $_output; } else { - return "<?php if ({$args['if condition']}){?>\n"; + return "<?php if ({$args['if condition']}){?>"; } } } @@ -53,7 +53,7 @@ class Smarty_Internal_Compile_Else extends Smarty_Internal_CompileBase { list($nesting, $compiler->tag_nocache) = $this->_close_tag(array('if', 'elseif')); $this->_open_tag('else',array($nesting,$compiler->tag_nocache)); - return "<?php }else{ ?>\n"; + return "<?php }else{ ?>"; } } @@ -79,13 +79,13 @@ class Smarty_Internal_Compile_Elseif extends Smarty_Internal_CompileBase { if (empty($this->compiler->prefix_code)) { $this->_open_tag('elseif', array($nesting, $compiler->tag_nocache)); - return "<?php }elseif({$args['if condition']}){?>\n"; + return "<?php }elseif({$args['if condition']}){?>"; } else { $tmp = ''; foreach ($this->compiler->prefix_code as $code) $tmp .= $code; $this->compiler->prefix_code = array(); $this->_open_tag('elseif', array($nesting + 1, $compiler->tag_nocache)); - return "<?php }else{?>{$tmp}<?php if ({$args['if condition']}){?>\n"; + return "<?php }else{?>{$tmp}<?php if ({$args['if condition']}){?>"; } } } @@ -107,7 +107,7 @@ class Smarty_Internal_Compile_Ifclose extends Smarty_Internal_CompileBase { list($nesting, $compiler->tag_nocache) = $this->_close_tag(array('if', 'else', 'elseif')); $tmp = ''; for ($i = 0; $i < $nesting ; $i++) $tmp .= '}'; - return "<?php {$tmp}?>\n"; + return "<?php {$tmp}?>"; } } |
