- bugfix {strip} must keep space on output creating smarty tags within html tags https://github.com/smarty-php/smarty/issues/177 other update for BC

This commit is contained in:
uwetews
2016-02-10 03:49:09 +01:00
parent 47237eb84f
commit b8fb986327
2 changed files with 3 additions and 4 deletions

View File

@@ -121,7 +121,7 @@ class Smarty extends Smarty_Internal_TemplateBase
/** /**
* smarty version * smarty version
*/ */
const SMARTY_VERSION = '3.1.30-dev/35'; const SMARTY_VERSION = '3.1.30-dev/36';
/** /**
* define variable scopes * define variable scopes

View File

@@ -832,13 +832,12 @@ abstract class Smarty_Internal_TemplateCompilerBase
$_store ++; $_store ++;
} }
} }
$space = $this->has_output && !preg_match('/^\s/', $text) ? ' ' : '';
} else { } else {
$text = preg_replace($this->stripRegEx, '', $text); $text = preg_replace($this->stripRegEx, '', $text);
} }
$space = $this->has_output && !preg_match('/^\s/', $text) ? ' ' : '';
$this->has_output = false;
} }
$this->has_output = false;
return new Smarty_Internal_ParseTree_Text($space . $text); return new Smarty_Internal_ParseTree_Text($space . $text);
} }
return null; return null;