/**
 * @author marje7
 */

function tabControl(obj, contentElem) {
	/*
		this func is attached to an A tag. it's parent node is an LI. it's grandparent node is a UL.
		to get an array of the LI items, we get the children of the grandparent.
		now we remove the current class from any/all of these LI elements.
	*/
	currentListItem = obj.parentNode;
	allListItems = currentListItem.parentNode.getElementsByTagName("li");
	
	for (i = 0; i < allListItems.length; i++) {
		allListItems[i].className = allListItems[i].className.replace(new RegExp(" current\\b"), "");
	}
	// make this one current
	currentListItem.className += ' current';
	// trigger the content elem to display using CS's function
	show_sched_element(contentElem);
}