

//this function will control layer scrolling - but is not finished yet.
function shoMe(id) {
	//var sellPoint = document.getElementById(id+"Txt");
	sellPoint = id+"Txt" //temp variable value to set href location
	//need code to get the top position of the selected sellPoint div and assign style.top value to scrollPoint
	var scrollPoint = 100;
	//sellPoint.parentNode.scrollTo(0,scrollPoint);
	location.href = "#"+sellPoint;// this will be deprecated once scrollTo() is working
}

/**
 * @return array
 * @param strTag, string
 * @param varType, variant
 * @desc returns an array of all strTag tags with the custom attribute "type" set to varType
*/
function getByTagAndType(strTag, varType) {
	var arrSuperSet = document.getElementsByTagName(strTag);
	var arrSubSet = new Array();
	var intSubSetCount = 0;
	for (var intSuperSetCount = 0; intSuperSetCount < arrSuperSet.length; intSuperSetCount++) {
		if (arrSuperSet[intSuperSetCount].getAttribute("type") == varType) {
			arrSubSet[intSubSetCount++] = arrSuperSet[intSuperSetCount];
		}
	}
	return arrSubSet;
}

//scrolls the div to top
function scrollUp(divNode) {
	if (isNS) {
		//don't know equivalent yet
	}
	else {
		divNode.doScroll("top");
	}
}

function getClass (node) {
	var nodeClass = node.className;
	return nodeClass;
}

function setClass (node, newClass) {
	node.className = newClass;
}

function setClassDeclaration(node, declaration, newValue) {
	//alert(node.id+', '+declaration+', '+newValue);
	node.style [declaration] = newValue;
	
}

//image rollover
function rollover(id) {
	///alert(id.substring(0,4));
	img = document.getElementById(id);
	src = img.src;
	ul = src.indexOf('_');
	path = src.substring(0, ul+1);
	stat = (src.charAt(ul+1) == 1)?0:1;
	sfx = src.substring(src.length-4, src.length);
	img.src = path+stat+sfx;
}

// Shows | hides the selected DIV element, populates content if specified
function showDiv(div, stat, content) {
	var divNode = document.getElementById(div);
	divNode.style.visibility = (stat)?'visible':'hidden';
	if (content) {
		loadContent(divNode, content);
	}
}

function loadContent(divNode, content) {
	var contentNode = document.getElementById(content);
	if (content !='') {
	divNode.innerHTML = contentNode.innerHTML;
	}
	else {
		divNode.innerHTML = '';
	}
}

//changes the window status bar to the given text
function winStat(strWinText) {
	window.status=strWinText;

}