| @@ 667-686 (lines=20) @@ | ||
| 664 | * |
|
| 665 | * @return bool |
|
| 666 | */ |
|
| 667 | public static function checkBrowserFirefox() |
|
| 668 | { |
|
| 669 | if (stripos(self::$userAgentString, 'safari') === false) { |
|
| 670 | if (preg_match("/Firefox[\/ \(]([^ ;\)]+)/i", self::$userAgentString, $matches)) { |
|
| 671 | if (isset($matches[1])) { |
|
| 672 | self::$browser->setVersion($matches[1]); |
|
| 673 | } |
|
| 674 | self::$browser->setName(Browser::FIREFOX); |
|
| 675 | ||
| 676 | return true; |
|
| 677 | } elseif (preg_match('/Firefox$/i', self::$userAgentString, $matches)) { |
|
| 678 | self::$browser->setVersion(''); |
|
| 679 | self::$browser->setName(Browser::FIREFOX); |
|
| 680 | ||
| 681 | return true; |
|
| 682 | } |
|
| 683 | } |
|
| 684 | ||
| 685 | return false; |
|
| 686 | } |
|
| 687 | ||
| 688 | /** |
|
| 689 | * Determine if the browser is SeaMonkey. |
|
| @@ 693-712 (lines=20) @@ | ||
| 690 | * |
|
| 691 | * @return bool |
|
| 692 | */ |
|
| 693 | public static function checkBrowserSeaMonkey() |
|
| 694 | { |
|
| 695 | if (stripos(self::$userAgentString, 'safari') === false) { |
|
| 696 | if (preg_match("/SeaMonkey[\/ \(]([^ ;\)]+)/i", self::$userAgentString, $matches)) { |
|
| 697 | if (isset($matches[1])) { |
|
| 698 | self::$browser->setVersion($matches[1]); |
|
| 699 | } |
|
| 700 | self::$browser->setName(Browser::SEAMONKEY); |
|
| 701 | ||
| 702 | return true; |
|
| 703 | } elseif (preg_match('/SeaMonkey$/i', self::$userAgentString, $matches)) { |
|
| 704 | self::$browser->setVersion(''); |
|
| 705 | self::$browser->setName(Browser::SEAMONKEY); |
|
| 706 | ||
| 707 | return true; |
|
| 708 | } |
|
| 709 | } |
|
| 710 | ||
| 711 | return false; |
|
| 712 | } |
|
| 713 | ||
| 714 | /** |
|
| 715 | * Determine if the browser is Iceweasel. |
|