var hija="";

function abrir(cual){open(cual,'_self','')}

function abrir2(cual){open(cual,'_blank','')}

function popup(cual,width,height){
	w2=width/2;
	h2=height/2;
	parametros="width="+width+",height="+height+",menubar=no";
	hija = open(cual,'temp',parametros)
	x = (screen.width/ 2)- w2;
	y = (screen.height/2) - h2; 
	hija.moveTo(x, y); 
}

function modal(url,w,h,t){
    Shadowbox.open({
		content: url,
		type:    "iframe",
		player:  "iframe",
		title:   t,
        width:   w,
		height:  h
	});
}

function muestra_producto(url){
	$("#maq_contenedor").load("load_jquery.php?url="+url)
/*
	$("#maq_contenedor").fadeOut(100,function(){
		$("#maq_contenedor").load("load_jquery.php?url="+url,function(){
			$("#maq_contenedor").slideDown(500);
	})
	})
*/
}



function enviar_forma(forma,dx,rst){
	var avalidar= new Array;
	var msj="";
	var titulo="";
	if(dx!=""){
		avalidar= dx.split(",");
		for(var i=0;i<avalidar.length;i++){
//			if(document.getElementById(avalidar[i]).value==document.getElementById(avalidar[i]).title){
			if(document.getElementById(avalidar[i]).value==""){
				titulo=document.getElementById(avalidar[i]).title;
				msj=msj+" » "+titulo+"\n";
			}
		}
	}
	if ((document.getElementById("correo").value.indexOf("@") == -1)||(document.getElementById("correo").value.indexOf(".") == -1)){
 		msj=msj+" » un correo electronico válido\n";
	}
	if(msj!=""){ alert("No se puede continuar, por favor indique:\n"+msj);}
	else {
		document.forms[forma].submit();
	}
}


	
