//small fix
git-svn-id: http://dev.prestashop.com/svn/v1/branches/1.5.x@8956 b9a71923-0436-4b27-9f14-aed3839534dd
This commit is contained in:
@@ -905,9 +905,7 @@ class AdminControllerCore extends Controller
|
|||||||
|
|
||||||
public function setMedia()
|
public function setMedia()
|
||||||
{
|
{
|
||||||
$this->addCSS(_PS_JS_DIR_.'jquery/datepicker/datepicker.css', 'all');
|
|
||||||
$this->addCSS(_PS_CSS_DIR_.'admin.css', 'all');
|
$this->addCSS(_PS_CSS_DIR_.'admin.css', 'all');
|
||||||
$this->addCSS(_PS_CSS_DIR_.'jquery.cluetip.css', 'all');
|
|
||||||
$this->addCSS(__PS_BASE_URI__.str_replace(_PS_ROOT_DIR_.DIRECTORY_SEPARATOR,'', _PS_ADMIN_DIR_).'/themes/default/admin.css', 'all');
|
$this->addCSS(__PS_BASE_URI__.str_replace(_PS_ROOT_DIR_.DIRECTORY_SEPARATOR,'', _PS_ADMIN_DIR_).'/themes/default/admin.css', 'all');
|
||||||
if ($this->context->language->is_rtl)
|
if ($this->context->language->is_rtl)
|
||||||
$this->addCSS(_THEME_CSS_DIR_.'rtl.css');
|
$this->addCSS(_THEME_CSS_DIR_.'rtl.css');
|
||||||
|
|||||||
+26
-11
@@ -179,17 +179,25 @@ abstract class ControllerCore
|
|||||||
if (is_array($css_uri))
|
if (is_array($css_uri))
|
||||||
foreach($css_uri as $css_file => $media)
|
foreach($css_uri as $css_file => $media)
|
||||||
{
|
{
|
||||||
if (is_string($css_file))
|
if (is_string($css_file) AND strlen($css_file) > 1)
|
||||||
{
|
{
|
||||||
if ($css_path = Media::getCSSPath($css_file, $media))
|
$css_path = Media::getCSSPath($css_file, $media);
|
||||||
$this->css_files = array_merge($css_path, $this->css_files);
|
if ($css_path)
|
||||||
|
$this->css_files = array_merge($css_path, $this->css_files);
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
$css_path = Media::getCSSPath($media, $css_media_type);
|
||||||
|
if ($css_path)
|
||||||
|
$this->css_files = array_merge($css_path, $this->css_files);
|
||||||
}
|
}
|
||||||
else if ($css_path = Media::getCSSPath($media, $css_media_type))
|
|
||||||
$this->css_files = array_merge($css_path, $this->css_files);
|
|
||||||
}
|
}
|
||||||
|
else if (is_string($css_uri) AND strlen($css_uri) > 1)
|
||||||
else if ($css_path = Media::getCSSPath($css_uri, $css_media_type))
|
{
|
||||||
$this->css_files = array_merge($css_path, $this->css_files);
|
$css_path = Media::getCSSPath($css_uri, $css_media_type);
|
||||||
|
if ($css_path)
|
||||||
|
$this->css_files = array_merge($css_path, $this->css_files);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@@ -202,10 +210,17 @@ abstract class ControllerCore
|
|||||||
{
|
{
|
||||||
if (is_array($js_uri))
|
if (is_array($js_uri))
|
||||||
foreach($js_uri as $js_file)
|
foreach($js_uri as $js_file)
|
||||||
if ($js_path = Media::getJSPath($js_file))
|
{
|
||||||
|
$js_path = Media::getJSPath($js_file);
|
||||||
|
if ($js_path)
|
||||||
$this->js_files[] = $js_path;
|
$this->js_files[] = $js_path;
|
||||||
else if ($js_path = Media::getJSPath($js_uri))
|
}
|
||||||
$this->js_files[] = $js_path;
|
else
|
||||||
|
{
|
||||||
|
$js_path = Media::getJSPath($js_uri);
|
||||||
|
if ($js_path)
|
||||||
|
$this->js_files[] = $js_path;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|||||||
Reference in New Issue
Block a user