[-] BO : fix #PSCFV-3910
git-svn-id: http://dev.prestashop.com/svn/v1/branches/1.5.x@17725 b9a71923-0436-4b27-9f14-aed3839534dd
This commit is contained in:
@@ -137,6 +137,12 @@ class ContextCore
|
|||||||
|
|
||||||
protected function checkMobileContext()
|
protected function checkMobileContext()
|
||||||
{
|
{
|
||||||
|
// Check mobile context
|
||||||
|
if (Tools::isSubmit('no_mobile_theme'))
|
||||||
|
Context::getContext()->cookie->no_mobile = true;
|
||||||
|
else if (Tools::isSubmit('mobile_theme_ok'))
|
||||||
|
Context::getContext()->cookie->no_mobile = false;
|
||||||
|
|
||||||
return isset($_SERVER['HTTP_USER_AGENT'])
|
return isset($_SERVER['HTTP_USER_AGENT'])
|
||||||
&& isset(Context::getContext()->cookie)
|
&& isset(Context::getContext()->cookie)
|
||||||
&& (bool)Configuration::get('PS_ALLOW_MOBILE_DEVICE')
|
&& (bool)Configuration::get('PS_ALLOW_MOBILE_DEVICE')
|
||||||
|
|||||||
@@ -252,12 +252,6 @@ class FrontControllerCore extends Controller
|
|||||||
CartRule::autoAddToCart($this->context);
|
CartRule::autoAddToCart($this->context);
|
||||||
}
|
}
|
||||||
|
|
||||||
// Check mobile context
|
|
||||||
if (Tools::isSubmit('no_mobile_theme'))
|
|
||||||
$this->context->cookie->no_mobile = true;
|
|
||||||
else if (Tools::isSubmit('mobile_theme_ok'))
|
|
||||||
$this->context->cookie->no_mobile = false;
|
|
||||||
|
|
||||||
$locale = strtolower(Configuration::get('PS_LOCALE_LANGUAGE')).'_'.strtoupper(Configuration::get('PS_LOCALE_COUNTRY').'.UTF-8');
|
$locale = strtolower(Configuration::get('PS_LOCALE_LANGUAGE')).'_'.strtoupper(Configuration::get('PS_LOCALE_COUNTRY').'.UTF-8');
|
||||||
setlocale(LC_COLLATE, $locale);
|
setlocale(LC_COLLATE, $locale);
|
||||||
setlocale(LC_CTYPE, $locale);
|
setlocale(LC_CTYPE, $locale);
|
||||||
|
|||||||
Reference in New Issue
Block a user