var xmlhttp = "";
/***** MOZILLA ******/
if (window.XMLHttpRequest)
	xmlhttp= new XMLHttpRequest();

/***** IE ******/
else if (window.ActiveXObject) {
	xmlhttp = new ActiveXObject("Microsoft.XMLHTTP");
}

/*function sideMenu(divId)
 {
	var divTag = new Array("officeMenu","retailMenu","hotelMenu","residentialMenu","industrialMenu","mixedMenu");
	var linkTag = new Array("officeLink","retailLink","hotelLink","residentialLink","industrialLink","mixedLink");

	for(i=0;i<divTag.length;i++)
	{
		if(document.getElementById(divTag[i]))
			document.getElementById(divTag[i]).style.display = "none";
		if(divTag[i] == divId)
		{
			dropdowncontent.init(linkTag[i], "", 300, "click")
		}else
		{
			dropdowncontent.hidediv(divTag[i]);
		}
		
	}
 }*/

function getDetails(id)
{
	var style = document.getElementById('changestyle');
	if(style.value!="")
		document.getElementById(style.value).className  = "";

	//document.getElementById(id).setAttribute("onclick", "");
	document.getElementById(id).className  = "current";
	style.value = id;	
/*	querystring = "id="+id;
	url = 'propertydetails.php?q=getDetail&'+querystring;
	document.getElementById('propDetail').innerHTML = "<div style='padding-left:95px; padding-top:135px;'><img src='images/common/loading.gif'></div>";
	xmlhttp.open('POST',url,true);
	xmlhttp.setRequestHeader('Content-Type','application/x-www-form-urlencoded; charset=UTF-8');
	xmlhttp.onreadystatechange = getDetails_stateChanged;
	xmlhttp.send(null);
*/}


function getDetails_stateChanged() 
{ 
	if (xmlhttp.readyState==4)
	{ 
		var str =xmlhttp.responseText;
		document.getElementById('propDetail').innerHTML = str;
		$(function() {
			// Use this example, or...
			$('a[@rel*=lightbox]').lightBox(); // Select all links that contains lightbox in the attribute rel
		});
	 }
}