@@ 697-716 (lines=20) @@ | ||
694 | * |
|
695 | * @return bool |
|
696 | */ |
|
697 | public static function checkBrowserFirefox() |
|
698 | { |
|
699 | if (stripos(self::$userAgentString, 'safari') === false) { |
|
700 | if (preg_match("/Firefox[\/ \(]([^ ;\)]+)/i", self::$userAgentString, $matches)) { |
|
701 | if (isset($matches[1])) { |
|
702 | self::$browser->setVersion($matches[1]); |
|
703 | } |
|
704 | self::$browser->setName(Browser::FIREFOX); |
|
705 | ||
706 | return true; |
|
707 | } elseif (preg_match('/Firefox$/i', self::$userAgentString, $matches)) { |
|
708 | self::$browser->setVersion(''); |
|
709 | self::$browser->setName(Browser::FIREFOX); |
|
710 | ||
711 | return true; |
|
712 | } |
|
713 | } |
|
714 | ||
715 | return false; |
|
716 | } |
|
717 | ||
718 | /** |
|
719 | * Determine if the browser is SeaMonkey. |
|
@@ 723-742 (lines=20) @@ | ||
720 | * |
|
721 | * @return bool |
|
722 | */ |
|
723 | public static function checkBrowserSeaMonkey() |
|
724 | { |
|
725 | if (stripos(self::$userAgentString, 'safari') === false) { |
|
726 | if (preg_match("/SeaMonkey[\/ \(]([^ ;\)]+)/i", self::$userAgentString, $matches)) { |
|
727 | if (isset($matches[1])) { |
|
728 | self::$browser->setVersion($matches[1]); |
|
729 | } |
|
730 | self::$browser->setName(Browser::SEAMONKEY); |
|
731 | ||
732 | return true; |
|
733 | } elseif (preg_match('/SeaMonkey$/i', self::$userAgentString, $matches)) { |
|
734 | self::$browser->setVersion(''); |
|
735 | self::$browser->setName(Browser::SEAMONKEY); |
|
736 | ||
737 | return true; |
|
738 | } |
|
739 | } |
|
740 | ||
741 | return false; |
|
742 | } |
|
743 | ||
744 | /** |
|
745 | * Determine if the browser is Iceweasel. |