mirror of
https://github.com/Lastorder-DC/rhymix.git
synced 2026-01-07 10:41:40 +09:00
Remove PHP5 only function from Mobile class.
git-svn-id: http://xe-core.googlecode.com/svn/branches/1.5.0@10606 201d5d3c-b55e-5fd7-737f-ddc643e51545
This commit is contained in:
parent
62a91e9c1f
commit
890c10dd2e
1 changed files with 5 additions and 2 deletions
|
|
@ -100,7 +100,8 @@ class Mobile {
|
|||
if(isset($UACheck)) return $UACheck;
|
||||
|
||||
$oMobile =& Mobile::getInstance();
|
||||
$mobileAgent = array('iPod','iPhone','Android','BlackBerry','SymbianOS','Bada','Kindle','Wii','SCH-','SPH-','CANU-','Windows Phone','Windows CE','POLARIS','Palm','Dorothy Browser','Mobile','Opera Mobi','Opera Mini','Minimo','AvantGo','NetFront','Nokia','LGPlayer','SonyEricsson','HTC','SKT','lgtelecom','Vodafone','DoCoMo');
|
||||
// stripos is only for PHP5.
|
||||
$mobileAgent = unserialize(strtolower(serialize(array('iPod','iPhone','Android','BlackBerry','SymbianOS','Bada','Kindle','Wii','SCH-','SPH-','CANU-','Windows Phone','Windows CE','POLARIS','Palm','Dorothy Browser','Mobile','Opera Mobi','Opera Mini','Minimo','AvantGo','NetFront','Nokia','LGPlayer','SonyEricsson','HTC','SKT','lgtelecom','Vodafone','DoCoMo'))));
|
||||
|
||||
if($oMobile->isMobilePadCheckByAgent())
|
||||
{
|
||||
|
|
@ -110,7 +111,9 @@ class Mobile {
|
|||
|
||||
foreach($mobileAgent as $agent)
|
||||
{
|
||||
if(stripos($_SERVER['HTTP_USER_AGENT'], $agent) !== FALSE)
|
||||
// stripos is only for PHP5..
|
||||
$httpUA = strtolower($_SERVER['HTTP_USER_AGENT']);
|
||||
if(strpos($httpUA, $agent) !== FALSE)
|
||||
{
|
||||
$UACheck = TRUE;
|
||||
return TRUE;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue