Skip to content

Commit

Permalink
serbanghita#373 - Support for windows 8.1
Browse files Browse the repository at this point in the history
  • Loading branch information
serbanghita committed Apr 25, 2015
1 parent dd91ec8 commit fc81cb5
Show file tree
Hide file tree
Showing 5 changed files with 1,737 additions and 5 deletions.
2 changes: 1 addition & 1 deletion Mobile_Detect.json

Large diffs are not rendered by default.

5 changes: 3 additions & 2 deletions Mobile_Detect.php
Original file line number Diff line number Diff line change
Expand Up @@ -584,8 +584,9 @@ class Mobile_Detect
// @reference: https://developer.mozilla.org/en-US/docs/User_Agent_Strings_Reference
'Firefox' => 'Firefox/[VER]',
'Fennec' => 'Fennec/[VER]',
// @reference: http://msdn.microsoft.com/en-us/library/ms537503(v=vs.85).aspx
'IE' => array('IEMobile/[VER];', 'IEMobile [VER]', 'MSIE [VER];'),
// http://msdn.microsoft.com/en-us/library/ms537503(v=vs.85).aspx
// https://msdn.microsoft.com/en-us/library/ie/hh869301(v=vs.85).aspx
'IE' => array('IEMobile/[VER];', 'IEMobile [VER]', 'MSIE [VER];', 'Trident/[0-9.]+;.*rv:[VER]'),
// http://en.wikipedia.org/wiki/NetFront
'NetFront' => 'NetFront/[VER]',
'NokiaBrowser' => 'NokiaBrowser/[VER]',
Expand Down
10 changes: 9 additions & 1 deletion examples/test.php
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@
var_dump($detect->version('iPhone'));
*/

/*
$user_agents = array(
'android' => 'Mozilla/5.0 (Linux; Android 4.2; Nexus 7 Build/JOP40C) AppleWebKit/535.19 (KHTML, like Gecko) Chrome/18.0.1025.166 Safari/535.19',
'iphone6' => 'Mozilla/5.0 (iPhone; CPU iPhone OS 6_0_1 like Mac OS X) AppleWebKit/536.26 (KHTML, like Gecko) Version/6.0 Mobile/10A523 Safari/8536.25',
Expand All @@ -18,4 +19,11 @@
{
$mobile_detect->setUserAgent($user_agent);
var_dump($mobile_detect->isAndroidOS());
}
}
*/

$detect = new Mobile_Detect;
//$detect->setUserAgent('Mozilla/5.0 (Windows NT 6.3; WOW64; Trident/7.0; rv:11.0) like Gecko');
//var_dump($detect->version('IE'));
$detect->setUserAgent('Mozilla/5.0 (Windows NT 6.3; WOW64; Trident/7.0; Touch; rv:11.0) like Gecko');
var_dump($detect->version('IE'));
Loading

0 comments on commit fc81cb5

Please sign in to comment.