
function getHTML(container,url,method,pars){

	//alert(url);
	
	var nAleatorio=Math.floor(Math.random()*1000000000); //creamos el número aleatorio
	var new_url = url + '&aleatorio=' + nAleatorio;

	//alert(new_url);

	document.getElementById(container).innerHTML = '<center><img src="../img/ajax-loader.gif"></center>';
	var myAjax = new Ajax.Updater(container,new_url,{ method: method, parameters: pars });

}


function getFormHTML(container,url,method,pars,formid){

	var nAleatorio=Math.floor(Math.random()*1000000000); //creamos el número aleatorio
	var new_url = url + '&aleatorio=' + nAleatorio;
	
	var params = Form.serialize($(formid));

	document.getElementById(container).innerHTML = '<center><img src="../img/ajax-loader.gif"></center>';
	var myAjax = new Ajax.Updater(container,new_url, {asynchronous:true, parameters:params} );

}


function getHTMLnoAjax(container,url){

	//alert(url);
	
	var nAleatorio=Math.floor(Math.random()*1000000000); //creamos el número aleatorio
	var new_url = url + '&aleatorio=' + nAleatorio;

	document.getElementById(container).innerHTML = new_url;

}



