You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

214 lines
6.0 KiB

7 years ago
  1. <?php
  2. defined('BASEPATH') OR exit('No direct script access allowed');
  3. /*
  4. | -------------------------------------------------------------------
  5. | USER AGENT TYPES
  6. | -------------------------------------------------------------------
  7. | This file contains four arrays of user agent data. It is used by the
  8. | User Agent Class to help identify browser, platform, robot, and
  9. | mobile device data. The array keys are used to identify the device
  10. | and the array values are used to set the actual name of the item.
  11. */
  12. $platforms = array(
  13. 'windows nt 10.0' => 'Windows 10',
  14. 'windows nt 6.3' => 'Windows 8.1',
  15. 'windows nt 6.2' => 'Windows 8',
  16. 'windows nt 6.1' => 'Windows 7',
  17. 'windows nt 6.0' => 'Windows Vista',
  18. 'windows nt 5.2' => 'Windows 2003',
  19. 'windows nt 5.1' => 'Windows XP',
  20. 'windows nt 5.0' => 'Windows 2000',
  21. 'windows nt 4.0' => 'Windows NT 4.0',
  22. 'winnt4.0' => 'Windows NT 4.0',
  23. 'winnt 4.0' => 'Windows NT',
  24. 'winnt' => 'Windows NT',
  25. 'windows 98' => 'Windows 98',
  26. 'win98' => 'Windows 98',
  27. 'windows 95' => 'Windows 95',
  28. 'win95' => 'Windows 95',
  29. 'windows phone' => 'Windows Phone',
  30. 'windows' => 'Unknown Windows OS',
  31. 'android' => 'Android',
  32. 'blackberry' => 'BlackBerry',
  33. 'iphone' => 'iOS',
  34. 'ipad' => 'iOS',
  35. 'ipod' => 'iOS',
  36. 'os x' => 'Mac OS X',
  37. 'ppc mac' => 'Power PC Mac',
  38. 'freebsd' => 'FreeBSD',
  39. 'ppc' => 'Macintosh',
  40. 'linux' => 'Linux',
  41. 'debian' => 'Debian',
  42. 'sunos' => 'Sun Solaris',
  43. 'beos' => 'BeOS',
  44. 'apachebench' => 'ApacheBench',
  45. 'aix' => 'AIX',
  46. 'irix' => 'Irix',
  47. 'osf' => 'DEC OSF',
  48. 'hp-ux' => 'HP-UX',
  49. 'netbsd' => 'NetBSD',
  50. 'bsdi' => 'BSDi',
  51. 'openbsd' => 'OpenBSD',
  52. 'gnu' => 'GNU/Linux',
  53. 'unix' => 'Unknown Unix OS',
  54. 'symbian' => 'Symbian OS'
  55. );
  56. // The order of this array should NOT be changed. Many browsers return
  57. // multiple browser types so we want to identify the sub-type first.
  58. $browsers = array(
  59. 'OPR' => 'Opera',
  60. 'Flock' => 'Flock',
  61. 'Edge' => 'Spartan',
  62. 'Chrome' => 'Chrome',
  63. // Opera 10+ always reports Opera/9.80 and appends Version/<real version> to the user agent string
  64. 'Opera.*?Version' => 'Opera',
  65. 'Opera' => 'Opera',
  66. 'MSIE' => 'Internet Explorer',
  67. 'Internet Explorer' => 'Internet Explorer',
  68. 'Trident.* rv' => 'Internet Explorer',
  69. 'Shiira' => 'Shiira',
  70. 'Firefox' => 'Firefox',
  71. 'Chimera' => 'Chimera',
  72. 'Phoenix' => 'Phoenix',
  73. 'Firebird' => 'Firebird',
  74. 'Camino' => 'Camino',
  75. 'Netscape' => 'Netscape',
  76. 'OmniWeb' => 'OmniWeb',
  77. 'Safari' => 'Safari',
  78. 'Mozilla' => 'Mozilla',
  79. 'Konqueror' => 'Konqueror',
  80. 'icab' => 'iCab',
  81. 'Lynx' => 'Lynx',
  82. 'Links' => 'Links',
  83. 'hotjava' => 'HotJava',
  84. 'amaya' => 'Amaya',
  85. 'IBrowse' => 'IBrowse',
  86. 'Maxthon' => 'Maxthon',
  87. 'Ubuntu' => 'Ubuntu Web Browser'
  88. );
  89. $mobiles = array(
  90. // legacy array, old values commented out
  91. 'mobileexplorer' => 'Mobile Explorer',
  92. // 'openwave' => 'Open Wave',
  93. // 'opera mini' => 'Opera Mini',
  94. // 'operamini' => 'Opera Mini',
  95. // 'elaine' => 'Palm',
  96. 'palmsource' => 'Palm',
  97. // 'digital paths' => 'Palm',
  98. // 'avantgo' => 'Avantgo',
  99. // 'xiino' => 'Xiino',
  100. 'palmscape' => 'Palmscape',
  101. // 'nokia' => 'Nokia',
  102. // 'ericsson' => 'Ericsson',
  103. // 'blackberry' => 'BlackBerry',
  104. // 'motorola' => 'Motorola'
  105. // Phones and Manufacturers
  106. 'motorola' => 'Motorola',
  107. 'nokia' => 'Nokia',
  108. 'palm' => 'Palm',
  109. 'iphone' => 'Apple iPhone',
  110. 'ipad' => 'iPad',
  111. 'ipod' => 'Apple iPod Touch',
  112. 'sony' => 'Sony Ericsson',
  113. 'ericsson' => 'Sony Ericsson',
  114. 'blackberry' => 'BlackBerry',
  115. 'cocoon' => 'O2 Cocoon',
  116. 'blazer' => 'Treo',
  117. 'lg' => 'LG',
  118. 'amoi' => 'Amoi',
  119. 'xda' => 'XDA',
  120. 'mda' => 'MDA',
  121. 'vario' => 'Vario',
  122. 'htc' => 'HTC',
  123. 'samsung' => 'Samsung',
  124. 'sharp' => 'Sharp',
  125. 'sie-' => 'Siemens',
  126. 'alcatel' => 'Alcatel',
  127. 'benq' => 'BenQ',
  128. 'ipaq' => 'HP iPaq',
  129. 'mot-' => 'Motorola',
  130. 'playstation portable' => 'PlayStation Portable',
  131. 'playstation 3' => 'PlayStation 3',
  132. 'playstation vita' => 'PlayStation Vita',
  133. 'hiptop' => 'Danger Hiptop',
  134. 'nec-' => 'NEC',
  135. 'panasonic' => 'Panasonic',
  136. 'philips' => 'Philips',
  137. 'sagem' => 'Sagem',
  138. 'sanyo' => 'Sanyo',
  139. 'spv' => 'SPV',
  140. 'zte' => 'ZTE',
  141. 'sendo' => 'Sendo',
  142. 'nintendo dsi' => 'Nintendo DSi',
  143. 'nintendo ds' => 'Nintendo DS',
  144. 'nintendo 3ds' => 'Nintendo 3DS',
  145. 'wii' => 'Nintendo Wii',
  146. 'open web' => 'Open Web',
  147. 'openweb' => 'OpenWeb',
  148. // Operating Systems
  149. 'android' => 'Android',
  150. 'symbian' => 'Symbian',
  151. 'SymbianOS' => 'SymbianOS',
  152. 'elaine' => 'Palm',
  153. 'series60' => 'Symbian S60',
  154. 'windows ce' => 'Windows CE',
  155. // Browsers
  156. 'obigo' => 'Obigo',
  157. 'netfront' => 'Netfront Browser',
  158. 'openwave' => 'Openwave Browser',
  159. 'mobilexplorer' => 'Mobile Explorer',
  160. 'operamini' => 'Opera Mini',
  161. 'opera mini' => 'Opera Mini',
  162. 'opera mobi' => 'Opera Mobile',
  163. 'fennec' => 'Firefox Mobile',
  164. // Other
  165. 'digital paths' => 'Digital Paths',
  166. 'avantgo' => 'AvantGo',
  167. 'xiino' => 'Xiino',
  168. 'novarra' => 'Novarra Transcoder',
  169. 'vodafone' => 'Vodafone',
  170. 'docomo' => 'NTT DoCoMo',
  171. 'o2' => 'O2',
  172. // Fallback
  173. 'mobile' => 'Generic Mobile',
  174. 'wireless' => 'Generic Mobile',
  175. 'j2me' => 'Generic Mobile',
  176. 'midp' => 'Generic Mobile',
  177. 'cldc' => 'Generic Mobile',
  178. 'up.link' => 'Generic Mobile',
  179. 'up.browser' => 'Generic Mobile',
  180. 'smartphone' => 'Generic Mobile',
  181. 'cellphone' => 'Generic Mobile'
  182. );
  183. // There are hundreds of bots but these are the most common.
  184. $robots = array(
  185. 'googlebot' => 'Googlebot',
  186. 'msnbot' => 'MSNBot',
  187. 'baiduspider' => 'Baiduspider',
  188. 'bingbot' => 'Bing',
  189. 'slurp' => 'Inktomi Slurp',
  190. 'yahoo' => 'Yahoo',
  191. 'ask jeeves' => 'Ask Jeeves',
  192. 'fastcrawler' => 'FastCrawler',
  193. 'infoseek' => 'InfoSeek Robot 1.0',
  194. 'lycos' => 'Lycos',
  195. 'yandex' => 'YandexBot',
  196. 'mediapartners-google' => 'MediaPartners Google',
  197. 'CRAZYWEBCRAWLER' => 'Crazy Webcrawler',
  198. 'adsbot-google' => 'AdsBot Google',
  199. 'feedfetcher-google' => 'Feedfetcher Google',
  200. 'curious george' => 'Curious George',
  201. 'ia_archiver' => 'Alexa Crawler',
  202. 'MJ12bot' => 'Majestic-12',
  203. 'Uptimebot' => 'Uptimebot'
  204. );