| @@ 731-750 (lines=20) @@ | ||
| 728 | * |
|
| 729 | * @return bool |
|
| 730 | */ |
|
| 731 | public static function checkBrowserFirefox() |
|
| 732 | { |
|
| 733 | if (stripos(self::$userAgentString, 'safari') === false) { |
|
| 734 | if (preg_match("/Firefox[\/ \(]([^ ;\)]+)/i", self::$userAgentString, $matches)) { |
|
| 735 | if (isset($matches[1])) { |
|
| 736 | self::$browser->setVersion($matches[1]); |
|
| 737 | } |
|
| 738 | self::$browser->setName(Browser::FIREFOX); |
|
| 739 | ||
| 740 | return true; |
|
| 741 | } elseif (preg_match('/Firefox$/i', self::$userAgentString, $matches)) { |
|
| 742 | self::$browser->setVersion(''); |
|
| 743 | self::$browser->setName(Browser::FIREFOX); |
|
| 744 | ||
| 745 | return true; |
|
| 746 | } |
|
| 747 | } |
|
| 748 | ||
| 749 | return false; |
|
| 750 | } |
|
| 751 | ||
| 752 | /** |
|
| 753 | * Determine if the browser is SeaMonkey. |
|
| @@ 757-776 (lines=20) @@ | ||
| 754 | * |
|
| 755 | * @return bool |
|
| 756 | */ |
|
| 757 | public static function checkBrowserSeaMonkey() |
|
| 758 | { |
|
| 759 | if (stripos(self::$userAgentString, 'safari') === false) { |
|
| 760 | if (preg_match("/SeaMonkey[\/ \(]([^ ;\)]+)/i", self::$userAgentString, $matches)) { |
|
| 761 | if (isset($matches[1])) { |
|
| 762 | self::$browser->setVersion($matches[1]); |
|
| 763 | } |
|
| 764 | self::$browser->setName(Browser::SEAMONKEY); |
|
| 765 | ||
| 766 | return true; |
|
| 767 | } elseif (preg_match('/SeaMonkey$/i', self::$userAgentString, $matches)) { |
|
| 768 | self::$browser->setVersion(''); |
|
| 769 | self::$browser->setName(Browser::SEAMONKEY); |
|
| 770 | ||
| 771 | return true; |
|
| 772 | } |
|
| 773 | } |
|
| 774 | ||
| 775 | return false; |
|
| 776 | } |
|
| 777 | ||
| 778 | /** |
|
| 779 | * Determine if the browser is Iceweasel. |
|