// Gillner JS Functions

//the main function, call to the effect object
function init(){
	
	var stretchers = document.getElementsByClassName('block'); //div that stretches
	var toggles = document.getElementsByClassName('title'); //h3s where I click on

	//accordion effect
	var myAccordion = new fx.Accordion(
		toggles, stretchers, {opacity: true, duration: 500}
	);

	function checkHash(){
		var found = false;
		toggles.each(function(h2, i){
			if (window.location.href.indexOf(h2.title) > 0) {
				myAccordion.showThisHideOpen(stretchers[i]);
				found = true;
			}
		});
		return found;
	}
}