function GetXmlHttpObject(){	var xmlHttp; try{		xmlHttp = new XMLHttpRequest();	}catch (e){		try{			xmlHttp = new ActiveXObject("Msxml2.XMLHTTP");		}catch (e){			try{				xmlHttp = new ActiveXObject("Microsoft.XMLHTTP");			}catch (e){				alert("Your browser does not support AJAX!");				return false;			}		}	}	return xmlHttp;}
function play_ustream(site_url,video_id)
{	
	xmlHttp_ustream = GetXmlHttpObject();
	
	if (xmlHttp_ustream == null)
 	{
 		alert ("Browser does not support HTTP Request");
 		return;
 	}
	
	var url_ustream=site_url+"/modules/ustream/ustream_api.php"; 
	url_ustream=url_ustream+"?video_id="+video_id;
	url_ustream=url_ustream+"&sid="+Math.random();
	
	xmlHttp_ustream.onreadystatechange = function()
	{
		if(xmlHttp_ustream.readyState == 4)
		{
			document.getElementById('ustream_content').innerHTML = xmlHttp_ustream.responseText;
		}
	}
	xmlHttp_ustream.open("GET",url_ustream,true);
	xmlHttp_ustream.send(null);
}
function play_utube(site_url,media_id)
{	
	xmlHttp_utube 	= GetXmlHttpObject();
	
	if (xmlHttp_utube == null)
 	{
 		alert ("Browser does not support HTTP Request");
 		return;
 	}
	
	var url_utube		= site_url+"/modules/ustream/utube_api.php"; 
	url_utube			= url_utube+"?media_id="+media_id;
	url_utube			= url_utube+"&sid="+Math.random();
	
	xmlHttp_utube.onreadystatechange = function()
	{
		if(xmlHttp_utube.readyState == 4)
		{
			document.getElementById('ustream_content').innerHTML = xmlHttp_utube.responseText;
		}
	}
	xmlHttp_utube.open("GET",url_utube,true);
	xmlHttp_utube.send(null);
}