From 71c43c90699030283231353faf8494d96274a0b9 Mon Sep 17 00:00:00 2001 From: Laurent Destailleur Date: Sat, 14 Apr 2012 03:18:42 +0200 Subject: [PATCH] Fix: debian epiphany and iceweasel browsers. --- htdocs/core/class/conf.class.php | 6 +++++- htdocs/install/mysql/data/llx_const.sql | 1 - 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/htdocs/core/class/conf.class.php b/htdocs/core/class/conf.class.php index a2c198124342d..d876dad3a8015 100644 --- a/htdocs/core/class/conf.class.php +++ b/htdocs/core/class/conf.class.php @@ -357,7 +357,11 @@ function setValues($db) $this->product->limit_size=$this->global->PRODUIT_LIMIT_SIZE; // conf->theme et $this->css - if (empty($this->global->MAIN_THEME)) $this->global->MAIN_THEME="eldy"; + if (empty($this->global->MAIN_THEME)) + { + if (isset($_SERVER["HTTP_USER_AGENT"]) && preg_match('/(epiphany|iceweasel)/i',$_SERVER["HTTP_USER_AGENT"])) $this->global->MAIN_THEME="auguria"; + else $this->global->MAIN_THEME="eldy"; + } $this->theme=$this->global->MAIN_THEME; $this->css = "/theme/".$this->theme."/style.css.php"; diff --git a/htdocs/install/mysql/data/llx_const.sql b/htdocs/install/mysql/data/llx_const.sql index 29301d68f0ffb..18a81459535d5 100644 --- a/htdocs/install/mysql/data/llx_const.sql +++ b/htdocs/install/mysql/data/llx_const.sql @@ -59,7 +59,6 @@ insert into llx_const (name, value, type, note, visible) values ('MAIN_MENUFRONT insert into llx_const (name, value, type, note, visible) values ('MAIN_MENU_SMARTPHONE','eldy_backoffice.php','chaine','Module de gestion de la barre de menu smartphone pour utilisateurs internes',0); insert into llx_const (name, value, type, note, visible) values ('MAIN_MENUFRONT_SMARTPHONE','eldy_frontoffice.php','chaine','Module de gestion de la barre de menu smartphone pour utilisateurs externes',0); -insert into llx_const (name, value, type, note, visible) values ('MAIN_THEME','eldy','chaine','Default theme',0); -- -- Delai tolerance