Changeset 456818
- Timestamp:
- 10/28/2011 07:09:07 PM (14 years ago)
- Location:
- wp-useragent/trunk
- Files:
-
- 14 added
- 2 edited
-
img/16/net/dorothybrowser.png (added)
-
img/16/net/firewebnavigator.png (added)
-
img/16/net/kylo.png (added)
-
img/16/net/nokia.png (added)
-
img/16/net/sundance.png (added)
-
img/16/net/webianshell.png (added)
-
img/16/os/inferno.png (added)
-
img/24/net/dorothybrowser.png (added)
-
img/24/net/firewebnavigator.png (added)
-
img/24/net/kylo.png (added)
-
img/24/net/nokia.png (added)
-
img/24/net/sundance.png (added)
-
img/24/net/webianshell.png (added)
-
img/24/os/inferno.png (added)
-
readme.txt (modified) (4 diffs)
-
wp-useragent.php (modified) (32 diffs)
Legend:
- Unmodified
- Added
- Removed
-
wp-useragent/trunk/readme.txt
r426533 r456818 4 4 Tags: useragent, user-agent, user agent, web, browser, web browser, operating system, platform, os, mac, apple, windows, win, linux, phone 5 5 Requires at least: 2.0 6 Tested up to: 3.2 7 Stable tag: 0.10. 96 Tested up to: 3.2.1 7 Stable tag: 0.10.10 8 8 9 9 == Description == … … 57 57 58 58 59 Some of you may compare this to another well-known plugin named browsersniff. UserAgent-Spyis a heavily modified and improved version of UserAgent-Spy, with several improvements over browsersniff also:59 Some of you may compare this to another well-known plugin named browsersniff. WP-UserAgent is a heavily modified and improved version of UserAgent-Spy, with several improvements over browsersniff also: 60 60 61 61 * Easy standard installation, just upload to wp-plugins and activate it. … … 66 66 67 67 == Changelog == 68 69 = v0.10.10 = 70 * Fixed Opera Next detection since the ua string has changed. 71 * Added detection for Opera Labs, Fireweb Navigator, Kylo, Sundance, Charon, Sylera, Dorothy Browser, and Webian Shell. 72 * Added detection for x64 versions of Unix/Linux. 73 * Added detection for the Inferno operating system. 74 * Added detection for Nokia Browser (props: Yomi) 75 68 76 69 77 = v0.10.9 = … … 512 520 * Reach a stable and solid 1.0 release where the plugin is mostly finalized and updates will generally be additional browsers and/or systems. 513 521 * New web browsers, devices and operating systems are always welcome. 522 * Add detection for PSVita when its released. 514 523 515 524 == Upgrade Notice == 516 525 517 = v0.10.8 = 518 * Added detection for Opera Next, Android Webkit and MiniBrowser. 526 = v0.10.10 = 527 * Fixed Opera Next detection since the ua string has changed. 528 * Added detection for Opera Labs, Fireweb Navigator, Kylo, Sundance, Charon, Sylera, Dorothy Browser, and Webian Shell. 529 * Added detection for x64 versions of Unix/Linux. 530 * Added detection for the Inferno operating system. 531 * Added detection for Nokia Browser (props: Yomi) -
wp-useragent/trunk/wp-useragent.php
r426533 r456818 4 4 Plugin URI: http://kyleabaker.com/goodies/coding/wp-useragent/ 5 5 Description: A simple User-Agent detection plugin that lets you easily insert icons and/or textual web browser and operating system details with each comment. 6 Version: 0.10. 96 Version: 0.10.10 7 7 Author: Kyle Baker 8 8 Author URI: http://kyleabaker.com/ … … 62 62 //fix for Opera's (and others) UA string changes in v10.00 63 63 $start=$title; 64 if((strtolower($title)==strtolower("Opera") || strtolower($title)==strtolower("Opera Next")) && preg_match('/Version/i', $useragent)) 64 if((strtolower($title)==strtolower("Opera") || strtolower($title)==strtolower("Opera Next") 65 || strtolower($title)==strtolower("Opera Labs")) && preg_match('/Version/i', $useragent)) 65 66 $start="Version"; 66 67 elseif(strtolower($title)==strtolower("Opera Mobi") && preg_match('/Version/i', $useragent)) … … 110 111 elseif(strtolower($title)=="tencenttraveler") 111 112 return "TT Explorer ".$version; 113 elseif(strtolower($title)=="opera labs") 114 { 115 preg_match('/Edition\ Labs([\ ._0-9a-zA-Z]+);/i', $useragent, $regmatch); 116 return $title.$regmatch[1]." ".$version; 117 } 112 118 else 113 119 return $title." ".$version; … … 126 132 $title="Abolimba"; 127 133 $code="abolimba"; 128 }elseif(preg_match('/ABrowse/i', $useragent)){129 $link="http://abrowse.sourceforge.net/";130 $title=detect_browser_version("ABrowse");131 $code="abrowse";132 134 }elseif(preg_match('/Acoo\ Browser/i', $useragent)){ 133 135 $link="http://www.acoobrowser.com/"; … … 210 212 $title="Cayman ".detect_browser_version("Browser"); 211 213 $code="caymanbrowser"; 214 }elseif(preg_match('/Charon/i', $useragent)){ 215 $link="http://en.wikipedia.org/wiki/Charon_(web_browser)"; 216 $title=detect_browser_version("Charon"); 217 $code="null"; 212 218 }elseif(preg_match('/Cheshire/i', $useragent)){ 213 219 $link="http://downloads.channel.aol.com/browser"; … … 294 300 $title=detect_browser_version("Doris"); 295 301 $code="doris"; 302 }elseif(preg_match('/Dorothy/i', $useragent)){ 303 $link="http://www.dorothybrowser.com/"; 304 $title=detect_browser_version("Dorothy"); 305 $code="dorothybrowser"; 296 306 }elseif(preg_match('/Edbrowse/i', $useragent)){ 297 307 $link="http://edbrowse.sourceforge.net/"; … … 330 340 $title=detect_browser_version("Firebird"); 331 341 $code="firebird"; 342 }elseif(preg_match('/Fireweb\ Navigator/i', $useragent)){ 343 $link="http://www.arsslensoft.tk/?q=node/7"; 344 $title=detect_browser_version("Fireweb Navigator"); 345 $code="firewebnavigator"; 332 346 }elseif(preg_match('/Flock/i', $useragent)){ 333 347 $link="http://www.flock.com/"; … … 478 492 $title=detect_browser_version("Konqueror"); 479 493 $code="konqueror"; 494 }elseif(preg_match('/Kylo/i', $useragent)){ 495 $link="http://kylo.tv/"; 496 $title=detect_browser_version("Kylo"); 497 $code="kylo"; 480 498 }elseif(preg_match('/LBrowser/i', $useragent)){ 481 499 $link="http://wiki.freespire.org/index.php/Web_Browser"; … … 610 628 $title=detect_browser_version("NF-Browser"); 611 629 $code="netfront"; 630 }elseif(preg_match('/NokiaBrowser/i', $useragent)){ 631 $link="http://browser.nokia.com/"; 632 $title="Nokia ".detect_browser_version("Browser"); 633 $code="nokia"; 612 634 }elseif(preg_match('/Novarra-Vision/i', $useragent)){ 613 635 $link="http://www.novarra.com/"; … … 634 656 $title=detect_browser_version("Opera Mobi"); 635 657 $code="opera-2"; 636 }elseif(preg_match('/Opera Next/i', $useragent)){ 658 }elseif(preg_match('/Opera Labs/i', $useragent) || (preg_match('/Opera/i', $useragent) && preg_match('/Edition Labs/i', $useragent))){ 659 $link="http://labs.opera.com/"; 660 $title=detect_browser_version("Opera Labs"); 661 $code="opera-next"; 662 }elseif(preg_match('/Opera Next/i', $useragent) || (preg_match('/Opera/i', $useragent) && preg_match('/Edition Next/i', $useragent))){ 637 663 $link="http://www.opera.com/support/kb/view/991/"; 638 664 $title=detect_browser_version("Opera Next"); … … 772 798 $title="Flock ".detect_browser_version("Sulfur"); 773 799 $code="flock"; 800 }elseif(preg_match('/Sundance/i', $useragent)){ 801 $link="http://digola.com/sundance.html"; 802 $title=detect_browser_version("Sundance"); 803 $code="sundance"; 774 804 }elseif(preg_match('/Sunrise/i', $useragent)){ 775 805 $link="http://www.sunrisebrowser.com/"; … … 788 818 $title=detect_browser_version("Swiftweasel"); 789 819 $code="swiftweasel"; 820 }elseif(preg_match('/Sylera/i', $useragent)){ 821 $link="http://dombla.net/sylera/"; 822 $title=detect_browser_version("Sylera"); 823 $code="null"; 790 824 }elseif(preg_match('/tear/i', $useragent)){ 791 825 $link="http://wiki.maemo.org/Tear"; … … 872 906 $title=detect_browser_version("Android Webkit"); 873 907 $code="android-webkit"; 908 }elseif(preg_match('/WebianShell/i', $useragent)){ 909 $link="http://webian.org/shell/"; 910 $title="Webian ".detect_browser_version("Shell"); 911 $code="webianshell"; 874 912 }elseif(preg_match('/WeltweitimnetzBrowser/i', $useragent)){ 875 913 $link="http://weltweitimnetz.de/software/Browser.en.page"; … … 898 936 899 937 //Pulled out of order to help ensure better detection for above browsers 938 }elseif(preg_match('/ABrowse/i', $useragent)){ 939 $link="http://abrowse.sourceforge.net/"; 940 $title=detect_browser_version("ABrowse"); 941 $code="abrowse"; 900 942 }elseif(preg_match('/Chrome/i', $useragent)){ 901 943 $link="http://google.com/chrome/"; … … 1220 1262 $title.=" ".$regmatch[1]; 1221 1263 $code="amigaos"; 1264 if(preg_match('/x86_64/i', $useragent)) 1265 $title.=" x64"; 1222 1266 }elseif(preg_match('/Android/i', $useragent)){ 1223 1267 $link="http://www.android.com/"; 1224 1268 $title="Android"; 1225 1269 $code="android"; 1270 if(preg_match('/x86_64/i', $useragent)) 1271 $title.=" x64"; 1226 1272 }elseif(preg_match('/[^A-Za-z]Arch/i', $useragent)) { //&& !preg_match('/Search/i', $useragent)){ 1227 1273 $link="http://www.archlinux.org/"; 1228 1274 $title="Arch Linux"; 1229 1275 $code="archlinux"; 1276 if(preg_match('/x86_64/i', $useragent)) 1277 $title.=" x64"; 1230 1278 }elseif(preg_match('/BeOS/i', $useragent)){ 1231 1279 $link="http://en.wikipedia.org/wiki/BeOS"; 1232 1280 $title="BeOS"; 1233 1281 $code="beos"; 1282 if(preg_match('/x86_64/i', $useragent)) 1283 $title.=" x64"; 1234 1284 }elseif(preg_match('/CentOS/i', $useragent)){ 1235 1285 $link="http://www.centos.org/"; … … 1238 1288 $title.=" ".$regmatch[1]; 1239 1289 $code="centos"; 1290 if(preg_match('/x86_64/i', $useragent)) 1291 $title.=" x64"; 1240 1292 }elseif(preg_match('/CrOS/i', $useragent)){ 1241 1293 $link="http://en.wikipedia.org/wiki/Google_Chrome_OS"; 1242 1294 $title="Google Chrome OS"; 1243 1295 $code="chromeos"; 1296 if(preg_match('/x86_64/i', $useragent)) 1297 $title.=" x64"; 1244 1298 }elseif(preg_match('/Debian/i', $useragent)){ 1245 1299 $link="http://www.debian.org/"; 1246 1300 $title="Debian GNU/Linux"; 1247 1301 $code="debian"; 1302 if(preg_match('/x86_64/i', $useragent)) 1303 $title.=" x64"; 1248 1304 }elseif(preg_match('/DragonFly/i', $useragent)){ 1249 1305 $link="http://www.dragonflybsd.org/"; 1250 1306 $title="DragonFly BSD"; 1251 1307 $code="dragonflybsd"; 1308 if(preg_match('/x86_64/i', $useragent)) 1309 $title.=" x64"; 1252 1310 }elseif(preg_match('/Edubuntu/i', $useragent)){ 1253 1311 $link="http://www.edubuntu.org/"; … … 1261 1319 if(strlen($version) > 1) 1262 1320 $title.=$version; 1321 if(preg_match('/x86_64/i', $useragent)) 1322 $title.=" x64"; 1263 1323 }elseif(preg_match('/Fedora/i', $useragent)){ 1264 1324 $link="http://www.fedoraproject.org/"; … … 1267 1327 $title.=" ".$regmatch[1]; 1268 1328 $code="fedora"; 1329 if(preg_match('/x86_64/i', $useragent)) 1330 $title.=" x64"; 1269 1331 }elseif(preg_match('/Foresight\ Linux/i', $useragent)){ 1270 1332 $link="http://www.foresightlinux.org/"; … … 1273 1335 $title.=" ".$regmatch[1]; 1274 1336 $code="foresight"; 1337 if(preg_match('/x86_64/i', $useragent)) 1338 $title.=" x64"; 1275 1339 }elseif(preg_match('/FreeBSD/i', $useragent)){ 1276 1340 $link="http://www.freebsd.org/"; 1277 1341 $title="FreeBSD"; 1278 1342 $code="freebsd"; 1343 if(preg_match('/x86_64/i', $useragent)) 1344 $title.=" x64"; 1279 1345 }elseif(preg_match('/Gentoo/i', $useragent)){ 1280 1346 $link="http://www.gentoo.org/"; 1281 1347 $title="Gentoo"; 1282 1348 $code="gentoo"; 1349 if(preg_match('/x86_64/i', $useragent)) 1350 $title.=" x64"; 1351 }elseif(preg_match('/Inferno/i', $useragent)){ 1352 $link="http://www.vitanuova.com/inferno/"; 1353 $title="Inferno"; 1354 $code="inferno"; 1355 if(preg_match('/x86_64/i', $useragent)) 1356 $title.=" x64"; 1283 1357 }elseif(preg_match('/IRIX/i', $useragent)){ 1284 1358 $link="http://www.sgi.com/partners/?/technology/irix/"; … … 1291 1365 } 1292 1366 $code="irix"; 1367 if(preg_match('/x86_64/i', $useragent)) 1368 $title.=" x64"; 1293 1369 }elseif(preg_match('/Kanotix/i', $useragent)){ 1294 1370 $link="http://www.kanotix.com/"; 1295 1371 $title="Kanotix"; 1296 1372 $code="kanotix"; 1373 if(preg_match('/x86_64/i', $useragent)) 1374 $title.=" x64"; 1297 1375 }elseif(preg_match('/Knoppix/i', $useragent)){ 1298 1376 $link="http://www.knoppix.net/"; 1299 1377 $title="Knoppix"; 1300 1378 $code="knoppix"; 1379 if(preg_match('/x86_64/i', $useragent)) 1380 $title.=" x64"; 1301 1381 }elseif(preg_match('/Kubuntu/i', $useragent)){ 1302 1382 $link="http://www.kubuntu.org/"; … … 1310 1390 if(strlen($version) > 1) 1311 1391 $title.=$version; 1392 if(preg_match('/x86_64/i', $useragent)) 1393 $title.=" x64"; 1312 1394 }elseif(preg_match('/LindowsOS/i', $useragent)){ 1313 1395 $link="http://en.wikipedia.org/wiki/Lsongs"; 1314 1396 $title="LindowsOS"; 1315 1397 $code="lindowsos"; 1398 if(preg_match('/x86_64/i', $useragent)) 1399 $title.=" x64"; 1316 1400 }elseif(preg_match('/Linspire/i', $useragent)){ 1317 1401 $link="http://www.linspire.com/"; 1318 1402 $title="Linspire"; 1319 1403 $code="lindowsos"; 1404 if(preg_match('/x86_64/i', $useragent)) 1405 $title.=" x64"; 1320 1406 }elseif(preg_match('/Linux\ Mint/i', $useragent)){ 1321 1407 $link="http://www.linuxmint.com/"; … … 1324 1410 $title.=" ".$regmatch[1]; 1325 1411 $code="linuxmint"; 1412 if(preg_match('/x86_64/i', $useragent)) 1413 $title.=" x64"; 1326 1414 }elseif(preg_match('/Lubuntu/i', $useragent)){ 1327 1415 $link="http://www.lubuntu.net/"; … … 1335 1423 if(strlen($version) > 1) 1336 1424 $title.=$version; 1425 if(preg_match('/x86_64/i', $useragent)) 1426 $title.=" x64"; 1337 1427 }elseif(preg_match('/Mac/i', $useragent) || preg_match('/Darwin/i', $useragent)){ 1338 1428 $link="http://www.apple.com/macosx/"; … … 1364 1454 $title.=" ".$regmatch[1]; 1365 1455 $code="mandriva"; 1456 if(preg_match('/x86_64/i', $useragent)) 1457 $title.=" x64"; 1366 1458 }elseif(preg_match('/moonOS/i', $useragent)){ 1367 1459 $link="http://www.moonos.org/"; … … 1370 1462 $title.=" ".$regmatch[1]; 1371 1463 $code="moonos"; 1464 if(preg_match('/x86_64/i', $useragent)) 1465 $title.=" x64"; 1372 1466 }elseif(preg_match('/MorphOS/i', $useragent)){ 1373 1467 $link="http://www.morphos-team.net/"; 1374 1468 $title="MorphOS"; 1375 1469 $code="morphos"; 1470 if(preg_match('/x86_64/i', $useragent)) 1471 $title.=" x64"; 1376 1472 }elseif(preg_match('/NetBSD/i', $useragent)){ 1377 1473 $link="http://www.netbsd.org/"; 1378 1474 $title="NetBSD"; 1379 1475 $code="netbsd"; 1476 if(preg_match('/x86_64/i', $useragent)) 1477 $title.=" x64"; 1380 1478 }elseif(preg_match('/OpenBSD/i', $useragent)){ 1381 1479 $link="http://www.openbsd.org/"; 1382 1480 $title="OpenBSD"; 1383 1481 $code="openbsd"; 1482 if(preg_match('/x86_64/i', $useragent)) 1483 $title.=" x64"; 1384 1484 }elseif(preg_match('/Oracle/i', $useragent)){ 1385 1485 $link="http://www.oracle.com/us/technologies/linux/"; … … 1390 1490 $title.=" Linux"; 1391 1491 $code="oracle"; 1492 if(preg_match('/x86_64/i', $useragent)) 1493 $title.=" x64"; 1392 1494 }elseif(preg_match('/PCLinuxOS/i', $useragent)){ 1393 1495 $link="http://www.pclinuxos.com/"; … … 1396 1498 $title.=" ".str_replace("_", ".", $regmatch[1]); 1397 1499 $code="pclinuxos"; 1500 if(preg_match('/x86_64/i', $useragent)) 1501 $title.=" x64"; 1398 1502 }elseif(preg_match('/Red\ Hat/i', $useragent) || preg_match('/RedHat/i', $useragent)){ 1399 1503 $link="http://www.redhat.com/"; … … 1402 1506 $title.=" Enterprise Linux ".str_replace("_", ".", $regmatch[1]); 1403 1507 $code="red-hat"; 1508 if(preg_match('/x86_64/i', $useragent)) 1509 $title.=" x64"; 1404 1510 }elseif(preg_match('/Sabayon/i', $useragent)){ 1405 1511 $link="http://www.sabayonlinux.org/"; 1406 1512 $title="Sabayon Linux"; 1407 1513 $code="sabayon"; 1514 if(preg_match('/x86_64/i', $useragent)) 1515 $title.=" x64"; 1408 1516 }elseif(preg_match('/Slackware/i', $useragent)){ 1409 1517 $link="http://www.slackware.com/"; 1410 1518 $title="Slackware"; 1411 1519 $code="slackware"; 1520 if(preg_match('/x86_64/i', $useragent)) 1521 $title.=" x64"; 1412 1522 }elseif(preg_match('/Solaris/i', $useragent)){ 1413 1523 $link="http://www.sun.com/software/solaris/"; … … 1422 1532 $title="openSUSE"; 1423 1533 $code="suse"; 1534 if(preg_match('/x86_64/i', $useragent)) 1535 $title.=" x64"; 1424 1536 }elseif(preg_match('/Symb[ian]?[OS]?/i', $useragent)){ 1425 1537 $link="http://www.symbianos.org/"; … … 1428 1540 $title.=" ".$regmatch[1]; 1429 1541 $code="symbianos"; 1430 }elseif(preg_match('/Ubuntu/i', $useragent)){ 1431 $link="http://www.ubuntu.com/"; 1432 $title="Ubuntu"; 1433 if(preg_match('/Ubuntu[\/|\ ]([.0-9a-zA-Z]+)/i', $useragent, $regmatch)) 1434 $version.=" ".$regmatch[1]; 1435 if($regmatch[1] < 10) 1436 $code="ubuntu-1"; 1437 else 1438 $code="ubuntu-2"; 1439 if(strlen($version) > 1) 1440 $title.=$version; 1542 if(preg_match('/x86_64/i', $useragent)) 1543 $title.=" x64"; 1441 1544 }elseif(preg_match('/Unix/i', $useragent)){ 1442 1545 $link="http://www.unix.org/"; 1443 1546 $title="Unix"; 1444 1547 $code="unix"; 1548 if(preg_match('/x86_64/i', $useragent)) 1549 $title.=" x64"; 1445 1550 }elseif(preg_match('/VectorLinux/i', $useragent)){ 1446 1551 $link="http://www.vectorlinux.com/"; 1447 1552 $title="VectorLinux"; 1448 1553 $code="vectorlinux"; 1554 if(preg_match('/x86_64/i', $useragent)) 1555 $title.=" x64"; 1449 1556 }elseif(preg_match('/Venenux/i', $useragent)){ 1450 1557 $link="http://www.venenux.org/"; 1451 1558 $title="Venenux GNU Linux"; 1452 1559 $code="venenux"; 1560 if(preg_match('/x86_64/i', $useragent)) 1561 $title.=" x64"; 1453 1562 }elseif(preg_match('/webOS/i', $useragent)){ 1454 1563 $link="http://en.wikipedia.org/wiki/WebOS"; … … 1522 1631 $title="Xandros"; 1523 1632 $code="xandros"; 1633 if(preg_match('/x86_64/i', $useragent)) 1634 $title.=" x64"; 1524 1635 }elseif(preg_match('/Xubuntu/i', $useragent)){ 1525 1636 $link="http://www.xubuntu.org/"; … … 1533 1644 if(strlen($version) > 1) 1534 1645 $title.=$version; 1646 if(preg_match('/x86_64/i', $useragent)) 1647 $title.=" x64"; 1535 1648 }elseif(preg_match('/Zenwalk/i', $useragent)){ 1536 1649 $link="http://www.zenwalk.org/"; 1537 1650 $title="Zenwalk GNU Linux"; 1538 1651 $code="zenwalk"; 1652 if(preg_match('/x86_64/i', $useragent)) 1653 $title.=" x64"; 1539 1654 1540 1655 //Pulled out of order to help ensure better detection for above platforms 1656 }elseif(preg_match('/Ubuntu/i', $useragent)){ 1657 $link="http://www.ubuntu.com/"; 1658 $title="Ubuntu"; 1659 if(preg_match('/Ubuntu[\/|\ ]([.0-9a-zA-Z]+)/i', $useragent, $regmatch)) 1660 $version.=" ".$regmatch[1]; 1661 if($regmatch[1] < 10) 1662 $code="ubuntu-1"; 1663 else 1664 $code="ubuntu-2"; 1665 if(strlen($version) > 1) 1666 $title.=$version; 1667 if(preg_match('/x86_64/i', $useragent)) 1668 $title.=" x64"; 1541 1669 }elseif(preg_match('/Linux/i', $useragent)){ 1542 1670 $link="http://www.linux.org/";
Note: See TracChangeset
for help on using the changeset viewer.