function advQuery() {
	var advMovie = 'movie/xboxadv.flv';
	var advLink = 'http://wp.tv';
	var show = false;
	sendAdvData(advLink, advMovie, show);
}
function sendAdvData(advLink, advMovie, show){
	ALERT('sendAdvData:\n'+advLink+'\n'+advMovie+'\n'+show, 'tekst');
	thisMovie("playerFlv").getAdvData(advLink, advMovie, show);
}
function changePlayerContent(_xml) {
	ALERT('changePlayerContent:\n'+_xml, 'tekst');
	thisMovie("playerFlv").changeContent(_xml);
}
function showSubscriptionsPopup(cid){
	ALERT('showSubscriptionsPopup:\n'+cid, 'tekst');
}
function showInformUsWindow(){
	ALERT('showInformUsWindow', 'tekst');
}
function moveToArchiwum(){
	ALERT('moveToArchiwum', 'tekst');
}
function planedMovie(a,b){
	ALERT('planedMovie:\n'+a+'\n'+b, 'tekst');
}
function movieStarted(movieId, title, nico){
	ALERT("movieStarted:\nmovieId: "+movieId+"\nTYTUŁ: "+title, 'tekst');
}
function changeMoviePoz(movieId, catId, pozStart, pozEnd){
	ALERT("changeMoviePoz:\nmovieId:"+movieId+" i catId:"+catId+" znajdujacego sie na pozycji "+pozStart+" na pozycje "+pozEnd, 'tekst');
}
function clearList(){
	ALERT("clearList", 'tekst');
}
function showGlorius(){
	ALERT("showGlorius", 'tekst');
}
function thisMovie(movieName) { 
	if (WP.isIE||WP.isOpera) return window[movieName]; else return document[movieName]; 
}
function getPlayerStatus(url, status, time, title, id, wptvType, tags, movieType, bytesTotal){
	ALERT('getPlayerStatus:\n'+'\nurl: '+url+'\nstatus: '+status+'\ntime: '+time+'\ntitle: '+title+'\nid: '+id+'\nwptvType: '+wptvType+'\ntags: '+tags+'\nmovieType: '+movieType+'\nbytesTotal: '+bytesTotal, 'tekst2');
}
function getPlayerIntervalStatus(time, url, movieType, bytesLoaded){
	ALERT('getPlayerIntervalStatus:\n'+'\ntime: '+time+'\nurl: '+url+'\nmovieType: '+movieType+'\nbytesLoaded: '+bytesLoaded, 'tekst2');
}
function playMovie(id, catId, nr) {
	document.location.href = '/mid,'+id+',wideo.html';
	// bez przeładowania: (opis, komentarze, itp zostają od poprzedniego materiału)
	// changePlayerContent('next.xml?mid='+id);
	ALERT('Funkcja playMovie()\nid:\t'+id+'\ncatId:\t'+catId+'\nnr:\t'+nr);
}
function ALERT(str, id){
	// debug
	// document.getElementById(id).innerHTML += "<br />"+str;
}

