//normal javascript
if(navigator.appName == "Microsoft Internet Explorer" && substr(navigator.appVersion, 0, 3) == '4.0'){
alert('IE8');
}else{
alert('not IE8');
}
//With jQuery
if($browser.msie && $browser.version == '8.0'){
alert('IE8');
}else{
alert('not IE8');
}
|