//===============================================================================
// DHTML functions, to create a common DHTML between IE, N4 and N6
//===============================================================================

//---------------------------------------------------------------------------------
// getBrowser - returns the browser type and version
// getObject  - gets an object id, returns a reference to the DHTML object
// getStyle   - gets an object id, returns a reference to the DHTML object's style
//---------------------------------------------------------------------------------

function getBrowser() {
    if (document.getElementById && navigator.appName == 'Netscape')
                                 return ( "N6" );       
    else if (document.all)       return ( "IE" );    //4 or 5
    else if (document.layers)    return ( "N4" );
    else                         return ( "other" );
}

//---------------------------------------------------------------------------------
function getObj(objID) {
    var browser = getBrowser();
    if (browser == "N6")         return( document.getElementById(objID) ); 
    if (browser == "IE")         return( document.all[objID]            ); 
    if (browser == "N4")         return( document.layers[objID]         ); 
}

//---------------------------------------------------------------------------------
function getStyle(objID) {
    var browser = getBrowser();
    if (browser == "N6")         return( document.getElementById(objID).style ); 
    if (browser == "IE")         return( document.all[objID].style            ); 
    if (browser == "N4")         return( document.layers[objID]               ); 
}

//---------------------------------------------------------------------------------