Determine if the browser is Lynx or not (last updated 1.7)
@return boolean True if the browser is Lynx otherwise false
343959
protected function checkBrowserLynx()
    {
        if (stripos($this->_agent, 'lynx') !== false) {
            $aresult = explode('/', stristr($this->_agent, 'Lynx'));
            $aversion = explode(' ', (isset($aresult[1]) ? $aresult[1] : ""));
            $this->setVersion($aversion[0]);
            $this->setBrowser(self::BROWSER_LYNX);

            return true;
        }

        return false;
    }
307354
private function isModern()
  {
    if ( !$this->forceBaseline && !$this->forceFallback )
    {
      switch ( $this->browser )
      {
        case "edge":
          return true;
        case 'msie':
          return ($this->major > 9);
          break;
        case 'chrome':
          return ( $this->major > 20 );
          break;
        case 'firefox':
          return ( $this->major > 27 );
          break;
        case 'opera':
          if ( $this->mobile )
          {
            return ( $this->major > 12 || ( $this->major == 11 && $this->minor >= 1 ) );
          }
          else
          {
            return ( $this->major > 11 || ( $this->major == 11 && $this->minor > 4 ) );
          }
          break;
        case 'safari':
          if(!$this->ios)
          {
            return ( $this->major > 6 || ( $this->major == 6 && $this->minor >= 1 ) );
          }
          else
          {
            return ( $this->major > 7 || ( $this->major == 7 && $this->minor >= 0 ) );
          }
          break;
        default:
          if ( $this->mobile )
          {
            if ( $this->android )
            {
              return ( $this->major > 4 || ( $this->major == 4 && $this->minor >= 4 ) );
            }
          }
      }
    }

    return false;
  }
151482
protected function checkBrowserYandex()
    {
        if (stripos($this->_agent, 'YaBrowser') !== false) {
            $aresult = explode('/', stristr($this->_agent, 'YaBrowser'));
            $aversion = explode(' ', $aresult[1]);
            $this->setVersion($aversion[0]);
            $this->setBrowser(self::BROWSER_YANDEX);

            return true;
        }

        return false;
    }
54044
public static function checkBrowserGsa()
    {
        if (stripos(self::$userAgentString, 'GSA') !== false) {
            $aresult = explode('/', stristr(self::$userAgentString, 'GSA'));
            if (isset($aresult[1])) {
                $aversion = explode(' ', $aresult[1]);
                self::$browser->setVersion($aversion[0]);
            }
            self::$browser->setName(Browser::GSA);

            return true;
        }

        return false;
    }
1307646
public static function checkBrowserNetPositive()
    {
        if (stripos(self::$userAgentString, 'NetPositive') !== false) {
            $aresult = explode('/', stristr(self::$userAgentString, 'NetPositive'));
            if (isset($aresult[1])) {
                $aversion = explode(' ', $aresult[1]);
                self::$browser->setVersion(str_replace(array('(', ')', ';'), '', $aversion[0]));
            }
            self::$browser->setName(Browser::NETPOSITIVE);

            return true;
        }

        return false;
    }
1107489
protected function checkBrowserAndroidKindleFire()
    {
        if( stripos($this->_agent,'Android') !== false )
        {
            if( stripos($this->_agent,'Silk') !== false )
            {
                $this->setVersion(self::VERSION_UNKNOWN);
                $this->setBrowser(self::BROWSER_KINDLE_FIRE);
                $this->setMobile(true);
                return true;
            }
        }
        return false;
    }
801194
public static function checkBrowserGaleon()
    {
        if (stripos(self::$userAgentString, 'galeon') !== false) {
            $aresult = explode(' ', stristr(self::$userAgentString, 'galeon'));
            $aversion = explode('/', $aresult[0]);
            if (isset($aversion[1])) {
                self::$browser->setVersion($aversion[1]);
            }
            self::$browser->setName(Browser::GALEON);

            return true;
        }

        return false;
    }
954030
public static function checkBrowserShiretoko()
    {
        if (stripos(self::$userAgentString, 'Mozilla') !== false &&
            preg_match('/Shiretoko\/([^ ]*)/i', self::$userAgentString, $matches)
        ) {
            if (isset($matches[1])) {
                self::$browser->setVersion($matches[1]);
            }
            self::$browser->setName(Browser::SHIRETOKO);

            return true;
        }

        return false;
    }
1112054
protected function checkBrowserQtWebBrowser() {
        if( stripos($this->_agent,'QtWebEngine') !== false ) {
            $aresult  = explode('/',stristr($this->_agent,'QtWebEngine'));
            $aversion = explode('.',$aresult[1]);
            $this->setVersion($aversion[0]);
            $this->setBrowser(self::BROWSER_QTWEB);
            return true;
        }
        return false;
    }
315137
public static function checkBrowserFirefox()
    {
        if (stripos(self::$userAgentString, 'safari') === false) {
            if (preg_match("/Firefox[\/ \(]([^ ;\)]+)/i", self::$userAgentString, $matches)) {
                if (isset($matches[1])) {
                    self::$browser->setVersion($matches[1]);
                }
                self::$browser->setName(Browser::FIREFOX);

                return true;
            } elseif (preg_match('/Firefox$/i', self::$userAgentString, $matches)) {
                self::$browser->setVersion('');
                self::$browser->setName(Browser::FIREFOX);

                return true;
            }
        }

        return false;
    }
239303
private function isSafari()
  {
    $is = false;
    if ( preg_match( "/(Version)\/(\d+)\.(\d+)(?:\.(\d+))?.*Safari\//", $this->ua, $matches ) )
    {
      // These things sometimes surf around acting like they're Safari.
      if ( !preg_match( "/(PhantomJS|Silk|rekonq|OPR|Chrome|Android|Edge|bot)/", $this->ua ) )
      {
        $is = true;
        $major = ( isset( $matches[ 2 ] ) ) ? $matches[ 2 ] : null;
        $minor = ( isset( $matches[ 3 ] ) ) ? $matches[ 3 ] : null;
        $rev = ( isset( $matches[ 4 ] ) ) ? $matches[ 4 ] : null;
        $version = ( isset( $major ) ) ? $major : null;
        $version .= ( isset( $minor ) ) ? '.' . $minor : null;
        $version .= ( isset( $rev ) ) ? '.' . $rev : null;
      }
    }
    // Versions below 3.x doe not have the Version/ in the UA.  Since we can't get the version number, we go with the
    // highest version that didn't have the version number in the UA.  It doesn't really matter, since this would be
    // a 'baseline' browser anyway.
    elseif ( preg_match("/(Safari)\/\d+/", $this->ua, $matches) )
    {
      // These things sometimes surf around acting like they're Safari.
      if ( !preg_match( "/(PhantomJS|Silk|rekonq|OPR|Chrome|Android|Edge|bot)/", $this->ua ) )
      {
        $is = true;
        $version = 2;
        $major = 2;
        $minor = 0;
        $rev = 4;
      }
    }

    if ( $is && isset( $version, $major, $minor ) )
    {
      $this->browser = 'safari';
      $this->version = $version;
      $this->major = $major;
      $this->minor = $minor;
      $this->rev = ( isset( $rev ) ) ? $rev : null;

      return true;
    }

    return false;
  }
1089948
protected function checkBrowserOmniWeb()
    {
        if (stripos($this->_agent, 'omniweb') !== false) {
            $aresult = explode('/', stristr($this->_agent, 'omniweb'));
            $aversion = explode(' ', isset($aresult[1]) ? $aresult[1] : '');
            $this->setVersion($aversion[0]);
            $this->setBrowser(self::BROWSER_OMNIWEB);
            return true;
        }
        return false;
    }
662423
protected function checkBrowserYandex()
    {
        if (stripos($this->_agent, 'YaBrowser') !== false) {
            $aresult = explode('/', stristr($this->_agent, 'YaBrowser'));
            if (isset($aresult[1])) {
                $aversion = explode(' ', $aresult[1]);
                $this->setVersion($aversion[0]);
                $this->setBrowser(self::BROWSER_YANDEX);

                if (stripos($this->_agent, 'iPad') !== false) {
                    $this->setTablet(true);
                } elseif (stripos($this->_agent, 'Mobile') !== false) {
                    $this->setMobile(true);
                } elseif (stripos($this->_agent, 'Android') !== false) {
                    $this->setTablet(true);
                }

                return true;
            }
        }

        return false;
    }
1345037
public static function checkBrowserSeaMonkey()
    {
        if (stripos(self::$userAgentString, 'safari') === false) {
            if (preg_match("/SeaMonkey[\/ \(]([^ ;\)]+)/i", self::$userAgentString, $matches)) {
                if (isset($matches[1])) {
                    self::$browser->setVersion($matches[1]);
                }
                self::$browser->setName(Browser::SEAMONKEY);

                return true;
            } elseif (preg_match('/SeaMonkey$/i', self::$userAgentString, $matches)) {
                self::$browser->setVersion('');
                self::$browser->setName(Browser::SEAMONKEY);

                return true;
            }
        }

        return false;
    }
22050
private function isChrome()
  {
    $is = false;
    // For our purposes, Chrome and Chromium are the same.
    if ( preg_match( "/(Chrome|Chromium)\/([0-9\.]+)/", $this->ua, $matches ) )
    {
      // These things go around acting like they are chrome, but they aren't.
      if ( !preg_match( "/(MRCHROME|FlyFlow|baidubrowser|bot|Edge)/i", $this->ua ) )
      {
        $is = true;
        $version = $matches[ 2 ];
        $parts = explode( '.', $matches[ 2 ] );
        $major = array_shift($parts);
        $minor = array_shift($parts);
        $rev = implode( '.', $parts );
      }
    }

    if ( $is && isset($version,$major,$minor,$rev) )
    {
      $this->browser = 'chrome';
      $this->version = $version;
      $this->major = $major;
      $this->minor = $minor;
      $this->rev = $rev;

      return true;
    }

    return false;
  }
12600
protected function checkBrowserShiretoko()
    {
        if (stripos($this->_agent, 'Mozilla') !== false && preg_match('/Shiretoko\/([^ ]*)/i', $this->_agent, $matches)) {
            $this->setVersion($matches[1]);
            $this->setBrowser(self::BROWSER_SHIRETOKO);
            return true;
        }
        return false;
    }
1317997
protected function checkBrowserEdge()
    {
        if (stripos($this->_agent, 'Edge/') !== false) {
            $aresult = explode('/', stristr($this->_agent, 'Edge'));
            if (isset($aresult[1])) {
                $aversion = explode(' ', $aresult[1]);
                $this->setVersion($aversion[0]);
                $this->setBrowser(self::BROWSER_EDGE);
                if (stripos($this->_agent, 'Windows Phone') !== false || stripos($this->_agent, 'Android') !== false) {
                    $this->setMobile(true);
                }
                return true;
            }
        }
        return false;
    }