diff --git a/bin/smarty_to_gettext.php b/bin/smarty_to_gettext.php index a14a2f7..eede459 100755 --- a/bin/smarty_to_gettext.php +++ b/bin/smarty_to_gettext.php @@ -81,7 +81,7 @@ function do_file($file) $content = $matches[3][$i]; if (!preg_match('/formatmatters\s*=\s*["\']?\s*(.[^\"\']*)\s*["\']?/', $matches[2][$i], $match)) { $replace = array( - '@[\n\r]+@' => ' ', + '@ *[\n\r]+@' => ' ', ); $content = preg_replace(array_keys($replace), array_values($replace), $content); } diff --git a/lib/templating/smartytemplate.inc.php b/lib/templating/smartytemplate.inc.php index eb45b86..28c8d90 100644 --- a/lib/templating/smartytemplate.inc.php +++ b/lib/templating/smartytemplate.inc.php @@ -118,7 +118,7 @@ class KTSmartyTemplate extends KTTemplate { $oi18n = $oRegistry->geti18n($sDomain); $content = trim($content); $replace = array( - '@[\n\r]+@' => ' ', + '@ *[\n\r]+@' => ' ', ); $content = preg_replace(array_keys($replace), array_values($replace), $content);