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