function maximize() {
if (top.location != location) top.location.href = location.href;
 self.moveTo(0,0);
 self.resizeTo(screen.availWidth,screen.availHeight);
}

function parent() {
if(top==self) { setTimeout("location='http://riflesdeaire.com'",2000)
 }
}

function autotime() {
setTimeout("location='http://riflesdeaire.com'",2000)
}

function Validar(form) {
if (form.email.value == "")
  { alert("Por favor ingrese su direccion de e-mail"); form.email.focus(); return; }  
if (form.email.value.indexOf('@', 0) == -1 || form.email.value.indexOf('.', 0) == -1 || form.email.value.indexOf(' ') != -1)
  { alert("Direccion de e-mail invalida verifiquela"); 
  form.email.focus(); return; }
if (form.Nombre.value == "")
  { alert("Por favor ingrese su nombre"); form.Nombre.focus(); return; }
if (form.Mensaje.value == "")
  { alert("Por favor ingrese su Mensaje"); form.Mensaje.focus(); return; }
form.submit();
}

function setpopup(mypage,myname,w,h) {
var win=null;
 {
  myleft=(screen.width)?(screen.width-w)/2:100; 
  mytop=(screen.height)?(screen.height-h)/2:100;
 }
settings="width=" + w + ",height=" + h + ",top=" + mytop + ",left=" + myleft + ",scrollbars=no,location=no,directories=no,status=no,menubar=no,toolbar=no,resizable=yes"; 
win=window.open(mypage,myname,settings);
win.focus();
}

function popupfla(swf,w,h) {
var imagename='', fla = swf + ".swf";
{
myleft=(screen.width)?(screen.width-w)/2:100; 
mytop=(screen.height)?(screen.height-h)/2:100;
}
OpenWin = this.open("","Gallery","toolbar=0,scrollbars=0,location=0,statusbar=0,menubar=0,resizable=yes,width=" + w + ",height=" + h + ", top=" + mytop + ",left=" + myleft + ";");
doc = OpenWin.document;
doc.write('<html><head><title>video curvac<\/title><\/head><BODY background="#000000" bgcolor="#000000" LEFTMARGIN="0" TOPMARGIN="0" MARGINWIDTH="0" MARGINHEIGHT="0"><center>');
doc.write('<object codeBase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=8,0,0,0" height="100%" width="100%" classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000">');
doc.write('<param NAME="Movie" VALUE="' + fla + '">');
doc.write('<param NAME="Loop" VALUE="-1">');
doc.write('<param NAME="bgcolor" VALUE=#000000>');
doc.write('<param NAME="Src" VALUE="' + fla + '">');
doc.write('<param NAME="WMode" VALUE="Window">');
doc.write('<embed src="' + fla + '" quality="high" pluginspage="http://www.macromedia.com/go/getflashplayer" type="application/x-shockwave-flash" width="100%" height="100%"></embed></Object>');
doc.write('<\/center><\/BODY><\/HTML>');
doc.close();
}

//---------------- popup + html + flash ---------------------------
function setpopup1(swf) {
var imagename='', w="240", h="180", fla = swf + ".swf";
{myleft=(screen.width)?(screen.width-w)/2:100; mytop=(screen.height)?(screen.height-h)/2:100;}
OpenWin = this.open("", "Gallery","toolbar=0,scrollbars=0,location=0,statusbar=0,menubar=0,resizable=yes,width=" + w + ",height=" + h + ", top=" + mytop + ",left=" + myleft + ";");
doc = OpenWin.document;
doc.write('<html><head><title>:: video curvac.com ::<\/title></head>');
doc.write('<BODY background="" bgcolor="#000000" LEFTMARGIN="0" TOPMARGIN="0" MARGINWIDTH="0" MARGINHEIGHT="0"> <center>');
doc.write('<object codeBase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,29,0" height="100%" width="100%" classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000">');
doc.write('<param NAME="Movie" VALUE="' + fla + '">');
doc.write('<param NAME="Loop" VALUE="-1">');
doc.write('<param NAME="bgcolor" VALUE=#FF0000>');
doc.write('<param NAME="Src" VALUE="' + fla + '">');
doc.write('<param NAME="WMode" VALUE="Window">');
doc.write('<embed src="' + fla + '" quality="high" pluginspage="http://www.macromedia.com/go/getflashplayer" type="application/x-shockwave-flash" width="100%" height="100%"></embed></Object>');
doc.write('<\/center><\/BODY><\/HTML>');
doc.close();
}

//---------------- popup + html + flash ---------------------------
function setpopup2(swf) {
var imagename='', w="160", h="118", fla = swf + ".swf";
{myleft=(screen.width)?(screen.width-w)/2:100; mytop=(screen.height)?(screen.height-h)/2:100;}
OpenWin = this.open("", "Gallery","toolbar=0,scrollbars=0,location=0,statusbar=0,menubar=0,resizable=yes,width=" + w + ",height=" + h + ", top=" + mytop + ",left=" + myleft + ";");
doc = OpenWin.document;
doc.write('<html><head><title>:: video curvac.com ::<\/title></head>');
doc.write('<BODY background="" bgcolor="#000000" LEFTMARGIN="0" TOPMARGIN="0" MARGINWIDTH="0" MARGINHEIGHT="0"> <center>');
doc.write('<object codeBase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,29,0" height="100%" width="100%" classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000">');
doc.write('<param NAME="Movie" VALUE="' + fla + '">');
doc.write('<param NAME="Loop" VALUE="-1">');
doc.write('<param NAME="bgcolor" VALUE=#FF0000>');
doc.write('<param NAME="Src" VALUE="' + fla + '">');
doc.write('<param NAME="WMode" VALUE="Window">');
doc.write('<embed src="' + fla + '" quality="high" pluginspage="http://www.macromedia.com/go/getflashplayer" type="application/x-shockwave-flash" width="100%" height="100%"></embed></Object>');
doc.write('<\/center><\/BODY><\/HTML>');
doc.close();
}
