Wednesday, February 11, 2009

DOM Exceptions

Found this very useful site which explains DOM Exceptions: W3C DOM Parser DOMException Object Documentation.

Wednesday, October 1, 2008

Browser Detect

var reg = new RegExp('/');
var navName = navigator.appName;
var brVer = navigator.userAgent;
var brNum; var brVerId;
if (navName == 'Microsoft Internet Explorer')
{
  brVerId = brVer.indexOf('MSIE');
  brNum = brVer.substr(brVerId, 8);
}
else verNumOt();
{
  brVerId = brVer.search(reg);
  brNum = brVer.substring(brVerId + 1);
}


brNum should contain
MSIE for IE
Firefox for Firefox
Chrome for Chrome
Safari for Safari
Navigator for Netscape
Flock for Flock
SeaMonkey for SeaMonkey

navName should contain
Opera for Opera
Netscape for Netscape, Firefox and SeaMonkey

AJAX Tricks

I've started reading some very interesting programming books and I found that, even though the content was awesome and I learned a lot more from these books than from years of programming hands-on experience, it was hard to go back and find a particular solution when needed. So I decided to compile my own list of Tricks and Tips so that I can easily find them when I need them the most.

Almost all of the tricks and tips here are extracted from one of the books listed on the left, but I will not specify which tip came from which book. I will also not copy/paste their content but rather create my own descriptions and titles. Furthermore, the tricks and tips in this list are just a tiny subset of everything found in these books. Thus, if you really want to learn something, you should consider purchasing these books at some point and maybe compiling a list of your own. I purchased all of them and I would have been sorry if i didn't.


This Blog is a part of the Tricks Series: