<!--
/*
	script by desu
	to change and detect DOM
*/

// declare variable to keep track for the DOM ref

	var isID =  0;
	var isAll = 0;
	var isLayers = 0;
	var isDHTML = 0;
	
	//make a function to detect the DOM.
	
function detectDOM()
{
	// if check to see if they use the standard DOM
	
	if(document.getElementById)
	{
		//turning on element
		isID = 1;
		isDHTML = 1;
	}

	// checck to se if they use MS object model

	else if (document.all)
	{
	isAll = 1;
	isDHTML = 1;
	}
	else if ((navigator.appName == "Netscape")&&(parseInt(navigator.appVersion) == 4))
	{
	isLayer = 1;
	isDHTML = 1;
	
	}
}

//make a function to return the proper reference to an element based on the DOM used.

function getRef(elemId, elemStyle)
{
	if(isID)
	{
		if(elemStyle)
		{
			return document.getElementById(elemId).style;
		} else {
			return document.getElementById(elemId)
		}
	}
	else if (isAll)
	{
		if (elemStyle)
		{
		return document.all(elemId).style;
		} else {
			return document.all[elemId]
		}
	
	} else if(isLayers)
	{
	
	
	return document.layers[elemId];
	}
	
}

 // -->

