Computer Magic Logo
Browser detect

Friday, January 22, 2016

Published by Aristotelis Pitaridis

Sometimes we want to do different things depending on the browser that the visitor uses in order to visit our web page. Below we can see how to find what are the capabilities of the visitor's browser.

if ($.browser.opera)
{
    // opera
}

if ($.browser.webkit)
{
    // webkit
}

if ($.browser.msie)
{
    // msie
}

if ($.browser.mozilla)
{
    // mozilla
}