var xmlHttp

function loadText(str)
{ 
xmlHttp=GetXmlHttpObject();
if (xmlHttp==null)
  {
  alert ("Your browser does not support AJAX!");
  return;
  } 
var url="loadText.php";
url=url+"?q="+str;
url=url+"&sid="+Math.random();
xmlHttp.onreadystatechange=stateChanged;
xmlHttp.open("GET",url,true);
xmlHttp.send(null);
}

function stateChanged() 
{ 
if (xmlHttp.readyState==4)
{ 


document.getElementById("txtHint").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;
}


function loadFile(theflv,theimg,thesrt,linkm,id) {

	jwplayer("player").setup({
		flashplayer: "player5.4/player.swf",
		
		image: "http://www.xprimm.tv/media/" + theimg,
		file: "http://www.xprimm.tv/media/" + theflv,
		autostart: true,
		skin: 'player5.5/modieus.swf',
		controlbar: "bottom",
		plugins: {
			sharing: {
				link: 'http://www.xprimm.tv/'+linkm,
				code:'<iframe id="frame" title="Xprimm TV" width="320" height="211" src="http://xprimm.tv/embed_id_ifm.php?id='+id+'" marginwidth="0" frameborder="0" scrolling="no" ></iframe>'
			},
			
		
		},
		height: 330,
		width: 533
	});
	


		loadText(id);
	
	
}

function loadFile_pub(theflv,theimg,thesrt,link,id) {

	jwplayer("player").setup({
		flashplayer: "player5.4/player.swf",
		
		image: "http://www.xprimm.tv/media/" + theimg,
		file: "http://www.xprimm.tv/media/" + theflv,
		
		skin: 'player5.5/modieus.swf',
		controlbar: "bottom",
		plugins: {
			sharing: {
				link: 'http://www.xprimm.tv/' + link,
				code:'<iframe id="frame" title="Xprimm TV" width="320" height="211" src="http://xprimm.tv/embed_id_ifm.php?id='+id+'" marginwidth="0" frameborder="0" scrolling="no" ></iframe>'
			},
			
			adtvideo:{config: 'player5.1/video_ad.xml'}
		
		},
		autostart: true,
		height: 330,
		width: 533
	});
	


		loadText(id);
	
	
}

function loadFileY(theFlv,theImg,id, go) {
	document.getElementById('player').innerHTML='Se incarca...';
	
	var s1 = new SWFObject("player/player-licensed.swf","player",533,330,7);
	s1.addParam("allowfullscreen","true");
	s1.addParam("wmode","transparent");
	s1.addVariable("file",'/media/'+theFlv);
	
	s1.addVariable("image","media/"+theImg);

 
	s1.addVariable('bufferlength',5);
	s1.addVariable('enablejs','false');
	
/*
	s1.addVariable('plugins','adtvideo');
	s1.addVariable('adtvideo.config', 'player/adsvideo.xml');
*/
s1.addVariable('skin','player5.1/modieus.swf');
s1.addVariable('plugins', 'adttext');

s1.addVariable('adttext.config', 'player/myconfig.xml');


	
if (go) { s1.addVariable("autostart","true"); }
	s1.write("player");
	


		
	
	
}

var selectEl = null; 

function select(el) {

if ( selectEl ) { 


selectEl.style.backgroundImage='url(img/backpld.jpg)';

}
selectEl = el;
 // new selected
document.getElementById('iconContainer').style.backgroundImage='url(img/backpld.jpg)';
el.style.backgroundImage="url(img/backpl.jpg)";


}

