var exists;
	var allStretch;
	
	//the main function, call to the effect object
	function init(){
		var divs = document.getElementsByClassName("stretcher");
		
		allStretch = new fx.MultiFadeSize(divs, {duration: 400});

		items = document.getElementsByClassName("display");
		for (i = 0; i < items.length; i++){
			var h2 = items[i];
			div = h2.nextSibling;
			div.style.display = 'block';
			h2.title = h2.className.replace("display ", "");

			if (window.location.href.indexOf(h2.title) < 0) {
				allStretch.hide(div, 'height');
				if (exists != true) exists = false;
			}
			else exists = true;
			
						
			h2.onclick = function(){
				allStretch.showThisHideOpen(this.nextSibling, 100, 'height');

					//this part for the arrows
					for (i = 0; i < items.length; i++){
						if (this == items[i]){
							this.firstChild.style.backgroundImage = 'url(images/minus.gif)';
							this.style.backgroundPosition = '0 -20px';
						}
						else {
							items[i].firstChild.style.backgroundImage = 'url(images/plus.gif)';
							items[i].style.backgroundPosition = '0 0';
						}
					}
				
				
			}
		}
		if (exists == false) {
			$('content').childNodes[1].fs.toggle('height');
			$('content').firstChild.firstChild.style.backgroundImage = 'url(images/minus.gif)';
			$('content').firstChild.style.backgroundPosition = '0 -20px';
			}
	}
