function imprimir(id){
		newWindow=window.open("paginas/especiales/imprimir.php?Id="+id,"Imprimir","left=200,top=150,height=400,width=600,scrollbars=1,menubar=0,resizable=0,status=0,titlebar=0,toolbar=0,target=_blank");
		newWindow.focus();
	}

function nuevoAjax(){
	/* Crea el objeto AJAX. Esta funcion es generica para cualquier utilidad de este tipo, por
	lo que se puede copiar tal como esta aqui */
	var xmlhttp=false;
	try{
		// Creacion del objeto AJAX para navegadores no IE
		xmlhttp=new ActiveXObject("Msxml2.XMLHTTP");
	}
	catch(e){
		try{
			// Creacion del objet AJAX para IE
			xmlhttp=new ActiveXObject("Microsoft.XMLHTTP");
		}catch(E) { xmlhttp=false; }
	}
	if (!xmlhttp && typeof XMLHttpRequest!='undefined') { xmlhttp=new XMLHttpRequest(); }

	return xmlhttp;
}

function setCookie(nombre,valor,expiredays){
	var exdate=new Date();
	exdate.setDate(exdate.getDate()+expiredays);
	document.cookie=nombre+ "=" +escape(valor)+
	((expiredays==null) ? "" : ";expires="+exdate.toUTCString());
}


function MostrarAviso(html, titulo){
	$('#div_aviso').attr('title',titulo);
	$('#div_aviso').css('zIndex',5000);
	if(html!=""){
		$('#div_aviso').html(html);
	}
	$('#div_aviso').dialog({
		autoOpen: true,
		width: 400,
		modal:true,
		resizable: false,
		dialogClass: 'dialog',
		closeOnEscape:true,
		beforeClose: function(){},
		show: "slide",
		zindex: 100,
		stack:true,
		buttons: {
			/*"Aceptar": function() {$(this).dialog( "close" );} */
			"Aceptar": function() {window.location="index.php";} 
		}
	});
}


