﻿<!--
function doNothing(){}
//DOM helper
function inv_clear(element)
{
    element.value='';
}
function XBrowser() { }
 
// detects Internet Explorer
XBrowser.isIE = document.all && window.ActiveXObject &&
    (navigator.userAgent.toLowerCase().indexOf('msie') > -1);
 
// Sets the 'class' of a DOM element

//useage: XBrowser.setClass(this,'myClass');
XBrowser.setClass = function setClass(element, val) {
    var attrName = (XBrowser.isIE ? 'className' : 'class');
    element.setAttribute(attrName, val);
}
    //useage: XBrowser.getClass(this);
XBrowser.getClass = function getClass(element) {
    var attrName = (XBrowser.isIE ? 'className' : 'class');
   return element.getAttribute(attrName); 
}

XBrowser.removeClass = function removeClass(element) {
    var attrName = (XBrowser.isIE ? 'className' : 'class');
   return element.removeAttribute(attrName); 
     
}

//use this to update an image - specify the elements ID and the path to the image
function inv_updateImage(theElementID,innerhtmlData)
{
        if (document.getElementById)
        {
            //get a Reference to 
            var elementToChange = document.getElementById(theElementID);
            elementToChange.innerHTML = innerhtmlData;
        }
}
//-->
