Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

Support whitespace characters when parsing simple tokens (see #5323)

  • Loading branch information...
commit 8d08a05c565f67418b2138170437f2fbfdeadffc 1 parent d8715b0
@leofeyer leofeyer authored
Showing with 5 additions and 2 deletions.
  1. +3 −0  CHANGELOG.md
  2. +2 −2 system/libraries/Controller.php
View
3  CHANGELOG.md
@@ -5,6 +5,9 @@ Version 2.11.9 (2013-XX-XX)
---------------------------
### Fixed
+Support whitespace characters when parsing simple tokens (see #5323).
+
+### Fixed
Allow to run multiple TinyMCE instances with different configurations on the
same page (thanks to Andreas Schempp) (see #4453).
View
4 system/libraries/Controller.php
@@ -2486,11 +2486,11 @@ protected function parseSimpleTokens($strBuffer, $arrData)
{
if (strncmp($strTag, '{if', 3) === 0)
{
- $strReturn .= preg_replace('/\{if ([A-Za-z0-9_]+)([=!<>]+)([^;$\(\)\[\] ]+).*\}/i', '<?php if ($arrData[\'$1\'] $2 $3): ?>', $strTag);
+ $strReturn .= preg_replace('/\{if ([A-Za-z0-9_]+)([=!<>]+)([^;$\(\)\[\]\}]+).*\}/i', '<?php if ($arrData[\'$1\'] $2 $3): ?>', $strTag);
}
elseif (strncmp($strTag, '{elseif', 7) === 0)
{
- $strReturn .= preg_replace('/\{elseif ([A-Za-z0-9_]+)([=!<>]+)([^;$\(\)\[\] ]+).*\}/i', '<?php elseif ($arrData[\'$1\'] $2 $3): ?>', $strTag);
+ $strReturn .= preg_replace('/\{elseif ([A-Za-z0-9_]+)([=!<>]+)([^;$\(\)\[\]\}]+).*\}/i', '<?php elseif ($arrData[\'$1\'] $2 $3): ?>', $strTag);
}
elseif (strncmp($strTag, '{else', 5) === 0)
{
Please sign in to comment.
Something went wrong with that request. Please try again.