X-Git-Url: https://git.mxchange.org/?p=core.git;a=blobdiff_plain;f=inc%2Fclasses%2Fmain%2Ftemplate%2Fclass_BaseTemplateEngine.php;h=c1aa4f8fc22f1be5be4675005f75ea9c5b1e617b;hp=b64477c4f10b41704cfbe582ba49b11ef1cfbfde;hb=fffe0ef5a4c39831127b1afed64d8ea0e077b09e;hpb=9108a2a3b038ee56833f7811accb49fdce2944e8 diff --git a/inc/classes/main/template/class_BaseTemplateEngine.php b/inc/classes/main/template/class_BaseTemplateEngine.php index b64477c4..c1aa4f8f 100644 --- a/inc/classes/main/template/class_BaseTemplateEngine.php +++ b/inc/classes/main/template/class_BaseTemplateEngine.php @@ -1496,27 +1496,27 @@ class BaseTemplateEngine extends BaseFrameworkSystem { /** * Removes all commentd, tabs and new-line characters to compact the content * - * @param $content The uncompacted content - * @return $content The compacted content + * @param $uncompactedContent The uncompacted content + * @return $compactedContent The compacted content */ - public function compactContent ($content) { + public function compactContent ($uncompactedContent) { // First, remove all tab/new-line/revert characters - $content = str_replace("\t", '', str_replace("\n", '', str_replace("\r", '', $content))); + $compactedContent = str_replace("\t", '', str_replace("\n", '', str_replace("\r", '', $uncompactedContent))); // Then regex all comments like away - preg_match_all('//', $content, $matches); + preg_match_all('//', $compactedContent, $matches); // Do we have entries? if (isset($matches[0][0])) { // Remove all foreach ($matches[0] as $match) { // Remove the match - $content = str_replace($match, '', $content); + $compactedContent = str_replace($match, '', $compactedContent); } // END - foreach } // END - if // Return compacted content - return $content; + return $compactedContent; } }