JavaScript: Browser Detection

From The Travis van der Font Wiki
Jump to: navigation, search
Check to see if Chrome or Chromium is the current user's browser. Returns true if so; otherwise, false.
var _isChrome = function ()
{
  return (/chrom(e|ium)/.test(navigator.userAgent.toLowerCase()));
}