View Single Post
Old 06-02-2014, 07:06 AM  
blackmonsters
Making PHP work
 
blackmonsters's Avatar
 
Industry Role:
Join Date: Nov 2002
Location: 🌎🌅🌈🌇
Posts: 20,620
Quote:
Originally Posted by k0nr4d View Post
I don't think this is as widespread as you might think - I haven't personally seen that happen very many times.
Sorry, but I made this post after looking at your tube script.

This is your code :

admin/functions.general.php

function detectMobile() {
...
...
...


case (stripos($user_agent,'android'));
$isMobile = true;
break;
case (stripos($user_agent,'iphone')||stripos($user_agen t,'ipod'));
$isMobile = true;
break;
case (stripos($user_agent,'opera mini'));
$isMobile = true;
break;
case (stripos($user_agent,'blackberry'));
$isMobile = true;
break;
...
...
...
...
...
...
}
return $isMobile;
}


It works just fine but only because the string is never in the first byte.
blackmonsters is offline   Share thread on Digg Share thread on Twitter Share thread on Reddit Share thread on Facebook Reply With Quote