// The css sheet has already set div.hidden display to 'none'. This is necessary in case the page loads slow, as with joomla.
// Now set the inline style OF THE ID (since toggleVisible uses id) to 'none', so they all stay hidden
var hiddenFaqsDivs = document.getElementById('visible').getElementsByTagName("div");
for (var i=0; i<hiddenFaqsDivs.length; i++) {
	document.getElementById(hiddenFaqsDivs[i].id).style.display = 'none';
}
// Now set the style sheet rule to ''. Now toggleVisible, which is inline style, will prevail.
var divHidden = getCSSRule('div.hidden');
divHidden.style.display ='';

function toggleVisible(id, anchor) {
	var item = document.getElementById(id);
	if (item.style.display) {
		item.style.display = '';
		anchor.getElementsByTagName("u")[0].style.background = 'url(/images/arrow_black_down.gif) no-repeat 0px 3px';
	}
	else {
		item.style.display = 'none';
		anchor.getElementsByTagName("u")[0].style.background = 'url(/images/arrow_black.gif) no-repeat 0px 3px';
	}
}

function getCSSRule(ruleName) {         			      // Return requested style obejct
ruleName=ruleName.toLowerCase();                       // Convert test string to lower case.
if (document.styleSheets) {                            // If browser can play with stylesheets
	for (var i=0; i<document.styleSheets.length; i++) { // For each stylesheet
		var styleSheet=document.styleSheets[i];          // Get the current Stylesheet
		var ii=0;                                        // Initialize subCounter.
		var cssRule=false;                               // Initialize cssRule. 
		do {                                             // For each rule in stylesheet
			if (styleSheet.cssRules) {                    // Browser uses cssRules?
				cssRule = styleSheet.cssRules[ii];         // Yes --Mozilla Style
			} else {                                      // Browser usses rules?
				cssRule = styleSheet.rules[ii];            // Yes IE style. 
			}                                             // End IE check.
			if (cssRule)  {                               // If we found a rule...
				if (cssRule.selectorText.toLowerCase()==ruleName) { //  match ruleName?
					return cssRule;                      // return the style object.
				}                                          // End found rule name
			}                                             // end found cssRule
			ii++;                                         // Increment sub-counter
		} while (cssRule)                                // end While loop
	}                                                   // end For loop
}                                                      // end styleSheet ability check
return false;                                          // we found NOTHING!
}        
