var spec_tags=new Array();

function getElementbyClass(objectID){
var inc=0
var alltags=document.all? document.all : document.getElementsByTagName("*")
for (i=0; i<alltags.length; i++){
	if (alltags[i].className==objectID)
	spec_tags[inc++]=alltags[i];
}}

function findpos(objectID){
theobject=document.getElementById(objectID);
var thearray=getElementbyClass('menu');
for (i=0; i<spec_tags.length; i++){
var menu_btn=spec_tags[i].getElementsByTagName('a')[0];
var the_one=menu_btn.className;
	if(the_one==objectID){
		//the mover trigger
		tdist=.001;
		x=.005;
		themove=setInterval("move_it(theobject)",1);
		///////////////////
	//menu_btn.style.color='#990000';
	//menu_btn.style.backgroundImage='url(../yoursite_main/img/library/mainbutton_active2.jpg)';
	object1=menu_btn.offsetParent.offsetLeft;
	theobject.style.left=object1+2+'px';
	theobject.style.MozOpacity=.05;
	theobject.style.filter='alpha(opacity=1)';
	//theobject.style.width=100+'px';
	theobject.style.display='block';
	
	}
	if(the_one!=objectID){
	//tdist=133;
	menu_btn.style.color='';
	//menu_btn.style.backgroundImage='url(../yoursite_main/img/library/bluegrad2.jpg)';
	theother=document.getElementById(the_one);
	//theobject.style.width=100+'px';
	theother.style.display='none';
	}
}}

function enterpos(objectID2){
theobject2=document.getElementById(objectID2);
theobject2.style.display='block';
theobject.style.MozOpacity=1;
theobject.style.filter='alpha(opacity=100)';
}

function leavepos(objectID2){
theobject2=document.getElementById(objectID2);
theobject2.style.display='none';
}

function move_it(theobject){
x=(x*1.2)/1;
tdist=tdist+x;
//theobject.style.top=tdist+'px';
theobject.style.MozOpacity=tdist;
theobject.style.filter='alpha(opacity='+tdist*100+')';
//document.getElementById("the_monitor").innerHTML=tdist;
if(tdist>1){
//document.getElementById("the_monitor2").innerHTML="interval cleared";
stopinterval();
}
}

function stopinterval(){
clearInterval(themove);
}

