Issue 1774, remove android tablet check. (There is no significant check value.)

git-svn-id: http://xe-core.googlecode.com/svn/branches/1.5.0@10589 201d5d3c-b55e-5fd7-737f-ddc643e51545
This commit is contained in:
misol 2012-04-21 16:28:33 +00:00
parent 9c5fa20b24
commit 2a62a0c3c5

View file

@ -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;
}
}