diff --git a/classes/mobile/Mobile.class.php b/classes/mobile/Mobile.class.php index 81051081f..aac5b75ae 100644 --- a/classes/mobile/Mobile.class.php +++ b/classes/mobile/Mobile.class.php @@ -128,25 +128,14 @@ class Mobile { { static $UACheck; if(isset($UACheck)) return $UACheck; - $padAgent = array('iPad','Android','webOS','hp-tablet','PlayBook'); - - // Android with 'Mobile' string is not a tablet-like device, and 'Andoroid' without 'Mobile' string is a tablet-like device. - $exceptionAgent = array('Android' => 'Mobile'); + $padAgent = array('iPad','webOS','hp-tablet','PlayBook'); foreach($padAgent as $agent) { if(strpos($_SERVER['HTTP_USER_AGENT'], $agent) !== FALSE) { - if(!isset($exceptionAgent[$agent])) - { - $UACheck = TRUE; - return TRUE; - } - elseif(strpos($_SERVER['HTTP_USER_AGENT'], $exceptionAgent[$agent]) === FALSE) - { - $UACheck = TRUE; - return TRUE; - } + $UACheck = TRUE; + return TRUE; } }