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;
}

function stateChanged() 
{ 
if (xmlHttp.readyState==4)
{ 
document.getElementById("txtHint").innerHTML=xmlHttp.responseText;
}
}
// EXAMPLE
function ajhost(url, div)
{
	xmlHttp=GetXmlHttpObject();
//	var url="post2.php?"+str;
	xmlHttp.onreadystatechange=function()
   {
		if(xmlHttp.readyState==4)
        {
			document.getElementById(div).innerHTML=xmlHttp.responseText;
//			$.unblockUI();
        }

    }
	xmlHttp.open("GET",url,true);
	xmlHttp.send(null);
}

function ajhost2(url, div)
{
	xmlHttp2=GetXmlHttpObject();
//	var url="post2.php?"+str;
	xmlHttp2.onreadystatechange=function()
   {
		if(xmlHttp2.readyState==4)
        {
			document.getElementById(div).innerHTML=xmlHttp2.responseText;
//			$.unblockUI();
        }

    }
	xmlHttp2.open("GET",url,true);
	xmlHttp2.send(null);
}



function ajaxtarhely(ertek) {
	ajhost('tarhely-rendeles-tartalom.php?pid='+ertek, 'csomagtartalom');	
	ajhost2('tarhely-rendeles-ara.php?pid='+ertek, 'csomagara');
}