
var arrDT = new Array();
var arrDD = new Array();
function toggleFAQ(theIndex) {
	thisDT = arrDT[theIndex]; thisDD = arrDD[theIndex];
	thisIMG = thisDT.getElementsByTagName('img');
	if (thisDD.className == "ddclosed") {
		thisDD.className = "ddopen";
		thisIMG[0].src = "http://filmblanc.info/images/minus_sm.gif";
	} else {
		thisDD.className = "ddclosed";
		thisIMG[0].src = "http://filmblanc.info/images/plus_sm.gif";
	}
}
function toggleAllFAQs(z) {
	thisImgSrc = (z == "closed") ? "http://filmblanc.info/images/plus_sm.gif" : "http://filmblanc.info/images/minus_sm.gif";
	for (i = 0; i <arrDT.length; i++) {
		arrDD[i].className = "dd"+z;
		arrDT[i].className = "dt"+z;
		thisIMG = arrDT[i].getElementsByTagName('img');
		thisIMG[0].src = thisImgSrc;
	}
}
function initFAQs() {
	theDLs = document.getElementById("faqcontent").getElementsByTagName('dl');
	for (j = 0; j < theDLs.length; j++) {
		var theDTs = theDLs[j].getElementsByTagName('dt');
		var theDDs = theDLs[j].getElementsByTagName('dd');
		if (theDTs.length != theDDs.length) { alert("Number of FAQ questions and answers do not match!\n\nTerminating FAQ initilization.\n\nPlease contact an administrator."); return }
		for (i=0; i < theDTs.length; i++) {
			thisIndex = arrDT.push(theDTs[i]) - 1; arrDD.push(theDDs[i]);
			thisDT = theDTs[i]; thisDD = theDDs[i];
			thisDT.onclick = new Function("toggleFAQ("+thisIndex+")");
			thisDT.className = "dtclosed";
			thisDD.className = "ddclosed";
		}
	}
}