animatedcollapse.addDiv('menu_properties', 'fade=1,speed=200,height=75px')
animatedcollapse.addDiv('menu_propertiesMember', 'fade=1,speed=200,height=100px')
animatedcollapse.addDiv('menu_buildings', 'fade=1,speed=200,height=50px')
animatedcollapse.addDiv('menu_agents', 'fade=1,speed=200,height=75px')
animatedcollapse.addDiv('menu_neighborhoods', 'fade=1,speed=300,height=175px')
animatedcollapse.addDiv('menu_press', 'fade=1,speed=200,height=50px')
animatedcollapse.addDiv('menu_about', 'fade=1,speed=200,height=75px')
animatedcollapse.addDiv('send_options', 'fade=1,speed=200,height=85px')
animatedcollapse.ontoggle=function($, divobj, state){ //fires each time a DIV is expanded/contracted
	//$: Access to jQuery
	//divobj: DOM reference to DIV being expanded/ collapsed. Use "divobj.id" to get its ID
	//state: "block" or "none", depending on state
}
animatedcollapse.init()

function nomenu(){
	animatedcollapse.hide('menu_properties');
	animatedcollapse.hide('menu_buildings');
	animatedcollapse.hide('menu_propertiesMember');
	animatedcollapse.hide('menu_agents');
	animatedcollapse.hide('menu_neighborhoods');
	animatedcollapse.hide('menu_press');
	animatedcollapse.hide('menu_about');
	animatedcollapse.hide('send_options');
}

function toggle(div){
	if(div!='menu_properties'){animatedcollapse.hide('menu_properties');}
	if(div!='menu_propertiesMember'){animatedcollapse.hide('menu_propertiesMember');}
	if(div!='menu_buildings'){animatedcollapse.hide('menu_buildings');}
	if(div!='menu_agents'){animatedcollapse.hide('menu_agents');}
	if(div!='menu_neighborhoods'){animatedcollapse.hide('menu_neighborhoods');}
	if(div!='menu_press'){animatedcollapse.hide('menu_press');}
	if(div!='menu_about'){animatedcollapse.hide('menu_about');}
	if(div!='send_options'){animatedcollapse.hide('send_options');}
	if(div != "null"){animatedcollapse.show(div);}
}

function rollLogo(X){
	var logo = document.getElementById('logo');
	logo.style.backgroundImage = "url(img/logo/adre"+X+".png)";
	
}

function rollStar(X,Y,Z){
	var star = document.getElementById(X+'N'+Y);
	star.style.backgroundImage = "url(img/star_"+Z+".png)";
	
}

function highlight(field) {
       field.focus();
       field.select();
}


function goTo() {
	var sE = null, url;
	if(document.getElementById) {
		sE = document.getElementById('urlList');
	} else if(document.all) {
		sE = document.all['urlList'];
	}
	if(sE && (url = sE.options[sE.selectedIndex].value)) {
		location.href = url;
	}
}


function autotab(current,to){
    if (current.getAttribute && 
      current.value.length==current.getAttribute("maxlength")) {
        to.focus() 
        }
}
