// JavaScript Document

/* START TAB FUNCTION */
	function findObj(id){return document.getElementById(id);}
	function setBlock(strName,intTabLength,intStart,unselect_class,select_class){
    	try{
			var strDivName=strName.substring(0,strName.indexOf("_"));
			var stri=strDivName;
        	for (var i=1; i<=intTabLength; i++){   
           		var temp=i+intStart;
           		if(temp<10)stri=strDivName+'_'+temp;
           		else stri=strDivName+'_'+temp;
           		findObj(stri).className=unselect_class;
           		findObj(findObj(stri).headers).style.display="none";
        	}
        	findObj(strName).className=select_class;
			findObj(findObj(strName).headers).style.display="block";
    	}
    	catch(ex){}
	}




// ------------------ image home --------------------------

/*function imgHome(imgName, imgTitle, imgLink){
	document.write("<div style='position: absolute;'><div style='width:110px;'><div class='imgTop'><div class='r'></div></div>" +
   	"<div class='imgMid'><div class='r'><div class='imgCtn'>");
		if (imgLink!=""){
			document.write("<a href='"+imgLink+"' style='border-bottom: 0'><img src='../images/photo/"+imgName+"' width='100px' height='73px' border='0px' title='"+imgTitle+"'></a>");
		}else{
			document.write("<img src='../images/photo/"+imgName+"' width='100px' height='73px' border='0px' title='"+imgTitle+"'>");
		}	
	document.write("</div></div></div><div class='imgBtm'><div class='r'></div></div></div></div>");
}

function imgBox(imgName, imgWidth, imgHeight, imgFloating, imgTitle, imgNameLink){
	var imgWidthBorder=imgWidth+10;
	var imgMargin;
	if (imgFloating=="left") imgMargin="0.3em 1.5em 1.5em 0.2em";
	else imgMargin="0.3em 0.2em 1.5em 1.5em";
	document.write("<div style='width:"+imgWidthBorder+"px; float:"+imgFloating+"; margin:"+imgMargin+"' class='imgBox'><div class='imgTop'><div class='r'></div></div><div class='imgMid'><div class='r'><div class='imgCtn'>");
	if (imgNameLink!=""){
		document.write("<a href='../images/photo/"+imgNameLink+"' rel='img' style='border-bottom:0' name='"+imgTitle+"'><span class='ico_enlarge'>&nbsp;</span><img src='../images/photo/"+imgName+"' width='"+imgWidth+"px' height='"+imgHeight+"px' title='"+imgTitle+"'></a>");
	}else{
		document.write("<img src='../images/photo/"+imgName+"' width='"+imgWidth+"px' height='"+imgHeight+"px' title='"+imgTitle+"'>");
	}
	document.write("</div></div></div><div class='imgBtm'><div class='r'></div></div><div class='imgTitle'>"+imgTitle+"</div></div>");
}


// -------- SEARCH -----------
	function qs(){ 
	var f=document.formSearch;
	var qe=f.searWords.value;
	if(window.encodeURIComponent)qe=encodeURIComponent(qe);		
	var pt=document.location.href;
	var iq=pt.indexOf('?');
	if(iq!=-1) pt=pt.substring(0, iq);
	if(f.action) 
		if(f.action!="") pt=f.action;
		var ue=pt+"?searWords="+qe;
		document.location=ue;
		return false;
}

*/