/* This script shows list items hidden by css.
The trigger for this is in the anchor:
onclick="showHiddenLinks(this, 'hiddenLink'); return false;"
"this" refers to the clicked link.
The second parameter is the class of list items which are hidden.
Whatever class you use to hide the list items should be included
in place of 'hiddenLink.'
Please note that for cases where a list item has multiple classes,
just use the class which actually does the hiding as a parameter. */
function showHiddenLinks(whichItem, whichClass) {
   if (!document.getElementById && !document.getElementsByTagName) return false;
// whichItem references the clicked link.
// We climb up from the link to the list item to the unordered list itself.
	theList = whichItem.parentNode.parentNode;
// Then we gather all the list items in the list.
	listItems = theList.getElementsByTagName("li")
// We create a new array to store the hidden list items in.
	hiddenLinks = new Array();
	for(var i = 0; i < listItems.length; i++) {
// We cycle through the list items and if any of them
// match the class which we supplied as a parameter,
// we put it into the "hiddenLinks" array.
// I've used a RegExp check in case a list item has multiple classes assigned.
		if(listItems[i].className.match(new RegExp("\\b" + whichClass + "\\b"))) {
			hiddenLinks.push(listItems[i]);
		}
	}
// Cycle through the hidden links and show them.
	for(var i = 0; i < hiddenLinks.length; i++) {
		hiddenLinks[i].style.display = "block";
	}
// Finally, since the hidden data is now visible,
// hide the anchor list item which the user clicked.
	whichItem.parentNode.style.display = "none";
}
