// Detect Browser

NetscapeNavigator = (document.layers) ? true : false;
InternetExplorer  = (document.all && !document.getElementById) ? 1 : 0;
if (!InternetExplorer) {
    InternetExplorer = (document.all && document.getElementById) ? 1 : 0;
}
Mozilla   = (!document.all && document.getElementById) ? 1 : 0;
VersioNum = parseFloat(navigator.appVersion);
Macintosh = navigator.userAgent.indexOf('Mac');

// Compability
rangeObj    =   ".";
styleObj    =   "";
nostyleObj  =   ".";
topObj      =   "top";
leftObj     =   "left";
heightObj   =   "clip.height";
widthObj    =   "clip.width";
hideObj     =   "visibility = 'hide'";
showObj     =   "visibility = 'show'";

if (InternetExplorer) {
    rangeObj    =   ".all.";
    styleObj    =   ".style";
    nostyleObj  =   ".";
    topObj      =   "pixelTop";
    leftObj     =   "pixelLeft";
    heightObj   =   "height";
    widthObj    =   "width";
    if (Macintosh == 36) {
        heightObj   =   "pixelHeight";
    }
    hideObj     =   "visibility = 'hidden'";
    showObj     =   "visibility = 'visible'";
}
else if (Mozilla) {
    rangeObj    =   ".getElementById('";
    styleObj    =   "').style";
    nostyleObj  =   "').";
    topObj      =   "offsetTop";
    leftObj     =   "offsetLeft";
    heightObj   =   "offsetHeight";
    widthObj    =   "offsetWidth";
    hideObj     =   "visibility = 'hidden'";
    showObj     =   "visibility = 'visible'";
}

