I wanted to share this with everyone as it's a function I would not be able to develop without... every project I start this is the first function I put into my code...
function obj(el) {
if( document.all ) {
return document.all(el);
} else {
return document.getElementById(el);
};
};
Basically what it allows me to do it is reference any object the in DOM by using the following...
obj('divid').style.backgroundColor ...