NukeViet\Client\Browser::checkBrowserFirefox PHP Метод

checkBrowserFirefox() защищенный Метод

Determine if the browser is Firefox or not (last updated 1.7)
protected checkBrowserFirefox ( ) : boolean
Результат boolean True if the browser is Firefox otherwise false
    protected function checkBrowserFirefox()
    {
        if (stripos($this->_agent, 'safari') === false) {
            if (preg_match("/Firefox[\\/ \\(]([^ ;\\)]+)/i", $this->_agent, $matches)) {
                $this->setVersion($matches[1]);
                $this->setBrowser(self::BROWSER_FIREFOX, self::BROWSER_FIREFOX_NAME);
                //Firefox on Android
                if (stripos($this->_agent, 'Android') !== false) {
                    if (stripos($this->_agent, 'Mobile') !== false) {
                        $this->setMobile(true);
                    } else {
                        $this->setTablet(true);
                    }
                }
                return true;
            } elseif (preg_match("/Firefox\$/i", $this->_agent, $matches)) {
                $this->setVersion("");
                $this->setBrowser(self::BROWSER_FIREFOX, self::BROWSER_FIREFOX_NAME);
                return true;
            }
        }
        return false;
    }