var xmlHttp

function showOfferta(id,place)
{ 
xmlHttp=GetXmlHttpObject();
if (xmlHttp==null)
  {
  alert ("Il vostro browser non supporta AJAX!");
  return;
  } 
var url="hostOfferte.asp";
url=url+"?id="+id;
url=url+"&place="+place;
url=url+"&sid="+Math.random();
if(place==1)
	{
	xmlHttp.onreadystatechange=stateChanged1;
	}
else if(place==2)
	{
	xmlHttp.onreadystatechange=stateChanged2;
	}
else if(place==3)
	{
	xmlHttp.onreadystatechange=stateChanged3;
	}
else if(place==4)
	{
	xmlHttp.onreadystatechange=stateChanged4;
	}
else if(place==5)
	{
	xmlHttp.onreadystatechange=stateChanged5;
	}
else if(place==6)
	{
	xmlHttp.onreadystatechange=stateChanged6;
	}
xmlHttp.open("GET",url,true);
xmlHttp.send(null);
}
	
function stateChanged1() 
	{ 
	if (xmlHttp.readyState==4)
		{ 
		document.getElementById("spazioOfferta1").innerHTML=xmlHttp.responseText;
		}
	}
	
function stateChanged2() 
	{ 
	if (xmlHttp.readyState==4)
		{ 
		document.getElementById("spazioOfferta2").innerHTML=xmlHttp.responseText;
		}
	}	
	
function stateChanged3() 
	{ 
	if (xmlHttp.readyState==4)
		{ 
		document.getElementById("spazioOfferta3").innerHTML=xmlHttp.responseText;
		}
	}
	
function stateChanged4() 
	{ 
	if (xmlHttp.readyState==4)
		{ 
		document.getElementById("spazioOfferta4").innerHTML=xmlHttp.responseText;
		}
	}
	
function stateChanged5() 
	{ 
	if (xmlHttp.readyState==4)
		{ 
		document.getElementById("spazioOfferta5").innerHTML=xmlHttp.responseText;
		}
	}	
	
function stateChanged6() 
	{ 
	if (xmlHttp.readyState==4)
		{ 
		document.getElementById("spazioOfferta6").innerHTML=xmlHttp.responseText;
		}
	}	

function GetXmlHttpObject()
{
var xmlHttp=null;
try
  {
  // Firefox, Opera 8.0+, Safari
  xmlHttp=new XMLHttpRequest();
  }
catch (e)
  {
  // Internet Explorer
  try
    {
    xmlHttp=new ActiveXObject("Msxml2.XMLHTTP");
    }
  catch (e)
    {
    xmlHttp=new ActiveXObject("Microsoft.XMLHTTP");
    }
  }
return xmlHttp;
}