From 6ada9a3639862e1e52c4027be89f2147afd5201e Mon Sep 17 00:00:00 2001 From: flyskyko Date: Mon, 4 Feb 2013 05:48:33 +0000 Subject: [PATCH] rollback 12571-12581 git-svn-id: http://xe-core.googlecode.com/svn/branches/luminous@12676 201d5d3c-b55e-5fd7-737f-ddc643e51545 --- classes/context/Context.class.php | 8 ++++---- classes/frontendfile/FrontEndFileHandler.class.php | 5 +---- 2 files changed, 5 insertions(+), 8 deletions(-) diff --git a/classes/context/Context.class.php b/classes/context/Context.class.php index 7fb544f39..90a7b4f87 100644 --- a/classes/context/Context.class.php +++ b/classes/context/Context.class.php @@ -741,12 +741,12 @@ class Context { foreach($charset_list as $charset) { - array_walk($obj,array('Context','checkConvertFlag'),$charset); + array_walk($obj,'Context::checkConvertFlag',$charset); $flag = Context::checkConvertFlag($flag = true); if($flag) { if($charset == 'UTF-8') return $obj; - array_walk($obj,array('Context','doConvertEncoding'),$charset); + array_walk($obj,'Context::doConvertEncoding',$charset); return $obj; } } @@ -767,7 +767,7 @@ class Context { if($charset) { if(is_array($val)) - array_walk($val,array('Context','checkConvertFlag'),$charset); + array_walk($val,'Context::checkConvertFlag',$charset); else if($val && iconv($charset,$charset,$val)!=$val) $flag = false; else $flag = false; } @@ -792,7 +792,7 @@ class Context { { if (is_array($val)) { - array_walk($val,array('Context','doConvertEncoding'),$charset); + array_walk($val,'Context::doConvertEncoding',$charset); } else $val = iconv($charset,'UTF-8',$val); } diff --git a/classes/frontendfile/FrontEndFileHandler.class.php b/classes/frontendfile/FrontEndFileHandler.class.php index ea2331181..6d301e3a2 100644 --- a/classes/frontendfile/FrontEndFileHandler.class.php +++ b/classes/frontendfile/FrontEndFileHandler.class.php @@ -102,10 +102,7 @@ $file->filePath = $this->_getAbsFileUrl($pathInfo['dirname']); $file->fileRealPath = FileHandler::getRealPath($pathInfo['dirname']); $file->fileExtension = strtolower($pathInfo['extension']); - - // Remove .min - $file->fileNameNoExt = preg_replace("/\.{$file->fileExtension}$/", '', $file->fileName); - $file->fileNameNoExt = preg_replace("/\.min$/", '', $file->fileNameNoExt); + $file->fileNameNoExt = preg_replace('/\.min$/', '', $pathInfo['filename']); $file->keyName = implode('.', array($file->fileNameNoExt, $file->fileExtension)); if(strpos($file->filePath, '://') === FALSE)