// 22/10/2007 22:17pm
// js/train-tv-channel.js
// urls
var uriBase = document.getElementById("urlIdentifier").getAttribute("content");
var urls = new Array();
urls['vlbt'] = uriBase+"ws/fre/vlbt-0.1.php5";
var globs = "apikey=nicowebv3";
/*
	* initBoxes ()
*/
function initBoxes () {
	
	// # enclenchement des img load
	$('boxLoad').style.display='inline';
	
	// # byEd
	var opts = { method : 'post' , parameters : globs+"&tag=métro,paris&page=1",
		onSuccess : function (r) { $('boxLoad').style.display='none'; }
		/*
		onFailure : function (r) { alert(r.responseText); }, 
		onComplete : function (r) { alert(r.responseText); }*/
	}
	new Ajax.Updater("listeVideo",urls['vlbt'],opts);

}

/*
	* updateBoxVideo ( string box , string val , int idPage )
*/
function updateBoxVideo (box,val,idPage) {
	// # enclenchement de img load
	$('boxLoad').style.display='inline';
	// # byTP
	var opts = { method : 'post' , parameters : globs+"&tag="+val+"&page="+idPage,
		onSuccess : function (r) { $('boxLoad').style.display='none'; }
		/*onFailure : function (r) { alert(r.responseText); }, 
		onComplete : function (r) { alert(r.responseText); }*/
	}
	new Ajax.Updater(box,urls['vlbt'],opts);
}
