From f7ff85b1bf9b16622efecc73fd40ff6a2c85c6fe Mon Sep 17 00:00:00 2001 From: vAugagneur Date: Fri, 23 Nov 2012 16:00:17 +0100 Subject: [PATCH] [-] CORE : fixed bug #PSCFV-5572 - getJqueryPluginCSSPath method does not pass folder argument --- classes/Media.php | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/classes/Media.php b/classes/Media.php index 8641821f0..b91fb3b8f 100755 --- a/classes/Media.php +++ b/classes/Media.php @@ -356,7 +356,7 @@ class MediaCore * @param mixed $name * @return void */ - public static function getJqueryPluginPath($name, $folder) + public static function getJqueryPluginPath($name, $folder = null) { $plugin_path = array('js' => array(), 'css' => array()); if ($folder === null) @@ -371,7 +371,7 @@ class MediaCore $plugin_path['js'] = Media::getJSPath($folder.$name.'/'.$file); else return false; - $plugin_path['css'] = Media::getJqueryPluginCSSPath($name); + $plugin_path['css'] = Media::getJqueryPluginCSSPath($name, $folder); return $plugin_path; } @@ -381,9 +381,10 @@ class MediaCore * @param mixed $name * @return void */ - public static function getJqueryPluginCSSPath($name) + public static function getJqueryPluginCSSPath($name, $folder) { - $folder = _PS_JS_DIR_.'jquery/plugins/'; + if ($folder === null) + $folder = _PS_JS_DIR_.'jquery/plugins/'; //set default folder $file = 'jquery.'.$name.'.css'; $url_data = parse_url($folder); $file_uri = _PS_ROOT_DIR_.Tools::str_replace_once(__PS_BASE_URI__, DIRECTORY_SEPARATOR, $url_data['path']);