PEAR :

Package :: Net_UserAgent_Mobile [PHP]:
  http://pear.php.net/package/Net_UserAgent_Mobile/

  これは便利かも.