From 5026216842c103d5c77a94fecaf9726ac5416b89 Mon Sep 17 00:00:00 2001 From: Hadi Nategh Date: Tue, 31 Mar 2015 13:55:05 +0000 Subject: [PATCH] Treat iceweasel browser like as firefox --- etemplate/inc/class.etemplate_new.inc.php | 2 +- phpgwapi/inc/class.html.inc.php | 5 +++++ 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/etemplate/inc/class.etemplate_new.inc.php b/etemplate/inc/class.etemplate_new.inc.php index 5e46cc7721..c524ecb874 100644 --- a/etemplate/inc/class.etemplate_new.inc.php +++ b/etemplate/inc/class.etemplate_new.inc.php @@ -198,7 +198,7 @@ class etemplate_new extends etemplate_widget_template // set action attribute for autocomplete form tag // as firefox complains on about:balnk action, thus we have to literaly submit the form to a blank html $form_action = "about:blank"; - if (html::$user_agent == 'firefox' || html::$user_agent =='iceweasel') $form_action = $GLOBALS['egw_info']['server']['webserver_url'].'/etemplate/empty.html'; + if (html::$user_agent == 'firefox') $form_action = $GLOBALS['egw_info']['server']['webserver_url'].'/etemplate/empty.html'; // check if we are in an ajax-exec call from jdots template (or future other tabbed templates) if (isset($GLOBALS['egw']->framework->response)) diff --git a/phpgwapi/inc/class.html.inc.php b/phpgwapi/inc/class.html.inc.php index 11770ad5b1..be1ad71cd5 100644 --- a/phpgwapi/inc/class.html.inc.php +++ b/phpgwapi/inc/class.html.inc.php @@ -86,6 +86,11 @@ class html self::$ua_version = preg_match('|Trident/[0-9.]+; rv:([0-9.]+)|i', $_SERVER['HTTP_USER_AGENT'], $matches) ? $matches[1] : 11.0; } + // iceweasel is based on mozilla and we treat it like as firefox + if (self::$user_agent == 'iceweasel') + { + self::$user_agent = 'firefox'; + } self::$ua_mobile = preg_match('/(iPhone|iPod|iPad|Android|SymbianOS|Blackberry|Kindle|Opera Mobi|Windows Phone)/i', $_SERVER['HTTP_USER_AGENT'], $matches) ? strtolower($matches[1]) : null;