Grab the RSS feed

Jquery Browser Finder

Hi friends,
Using Jquery we can find the browser.This is going to be very useful when the codings on depending upon the browser oriented.At that time we ca change our coding by finding the browser.So it will take less minutes to solve the issues depending on browser.
All credits goes to akchauhan

< !DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd" > 
< html xmlns="http://www.w3.org/1999/xhtml" > 
< head > 
< script type="text/javascript" src="jquery/jquery-1.3.2.min.js" > < /script > 
< script type="text/javascript" > 
$(document).ready(function(){

var browser;
if($.browser.mozilla)
browser = "Firefox";
else if($.msie)
browser = "Internet Explorer";
else if($.browser.opera)
browser = "Opera";
else if($.browser.safari)
browser = "Safari";
else
browser = "Unknown";

$('#browserName').append(browser);
});
< /script > 

< meta http-equiv="Content-Type" content="text/html; charset=utf-8" / > 
< title > Browser Finder< /title > 


< body > 
< div id="browserName" > Your Browser: < /div > 
< /body > 
< /html > 


Leave the comments to improve us..

0 comments:

  •  
    Real Time Web Analytics