summaryrefslogtreecommitdiff
path: root/forum/utils/clientinfo.php
diff options
context:
space:
mode:
authordeva <deva>2008-10-04 10:38:03 +0000
committerdeva <deva>2008-10-04 10:38:03 +0000
commitcce5e7710295021b41d9aaecc503a60fb99256be (patch)
tree660235be91fb821e976c7ae62347eb368ce87524 /forum/utils/clientinfo.php
Initial revision
Diffstat (limited to 'forum/utils/clientinfo.php')
-rw-r--r--forum/utils/clientinfo.php24
1 files changed, 24 insertions, 0 deletions
diff --git a/forum/utils/clientinfo.php b/forum/utils/clientinfo.php
new file mode 100644
index 0000000..cbb7a4d
--- /dev/null
+++ b/forum/utils/clientinfo.php
@@ -0,0 +1,24 @@
+<?php
+/*
+Jonas Mobil:
+"SonyEricssonW660i/R6BC Browser/NetFront/3.3 Profile/MIDP-2.0 Configuration/CLDC-1.1"
+
+Rasmus Mobil:
+"Mozilla/5.0 (SymbianOS/9.2; U; Series60/3.1 NokiaN81-3/11.0.045 Profile/MIDP-2.0 Configuration/CLDC-1.1 ) AppleWebKit/413 (KHTML, like Gecko) Safari/413"
+*/
+
+ //echo $_SERVER['HTTP_USER_AGENT'] . "<br/>";
+$client_is_mobile_device =
+ stripos($_SERVER['HTTP_USER_AGENT'], "MIDP") != FALSE
+ || stripos($_SERVER['HTTP_USER_AGENT'], "Nokia") != FALSE
+ || stripos($_SERVER['HTTP_USER_AGENT'], "Sony") != FALSE
+ || stripos($_SERVER['HTTP_USER_AGENT'], "Ericson") != FALSE
+ || $_GET['forcemobile'];
+
+//$client_is_mobile_device = !$client_is_mobile_device;
+/*
+echo "client_is_mobile_device = ";
+if($client_is_mobile_device) echo "yes";
+ else echo "no";
+*/
+?> \ No newline at end of file