/*** comunes.js ***/

function popNewWin(mypage,w,h){
  var winl = (screen.width-w)/2;
  var wint = (screen.height-h)/2;
  var settings  ='height='+h;
      settings +=',width='+w;
      settings +=',top='+wint;
      settings +=',left='+winl;
      settings +=',scrollbars=auto';
      settings +=',resizable=yes';
  var win=window.open(mypage,"nw",settings);
  win.focus();
}


function popNewWin2(mypage,w,h){
  var winl = (screen.width-w)/2;
  var wint = (screen.height-h)/2;
  var settings  ='height='+h;
      settings +=',width='+w;
      settings +=',top='+wint;
      settings +=',left='+winl;
      settings +=',scrollbars=auto';
      settings +=',resizable=yes';
  var win=window.open(mypage,"nw2",settings);
  win.focus();
}

function popNewWin3(mypage,w,h){
  var winl = (screen.width-w)/2;
  var wint = (screen.height-h)/2;
  var settings  ='height='+h;
      settings +=',width='+w;
      settings +=',top='+wint;
      settings +=',left='+winl;
      settings +=',scrollbars=auto';
      settings +=',resizable=yes';
  var win=window.open(mypage,"nw3",settings);
  win.focus();
}

function popNewWin4(mypage,w,h){
  var winl = (screen.width-w)/2;
  var wint = (screen.height-h)/2;
  var settings  ='height='+h;
      settings +=',width='+w;
      settings +=',top='+wint;
      settings +=',left='+winl;
      settings +=',scrollbars=auto';
      settings +=',resizable=yes';
  var win=window.open(mypage,"nw4",settings);
  win.focus();
}

function popNewWin5(mypage,w,h){
  var winl = (screen.width-w)/2;
  var wint = (screen.height-h)/2;
  var settings  ='height='+h;
      settings +=',width='+w;
      settings +=',top='+wint;
      settings +=',left='+winl;
      settings +=',scrollbars=auto';
      settings +=',resizable=yes';
  var win=window.open(mypage,"nw5",settings);
  win.focus();
}

function popNewWin6(mypage,w,h){
  var winl = (screen.width-w)/2;
  var wint = (screen.height-h)/2;
  var settings  ='height='+h;
      settings +=',width='+w;
      settings +=',top='+wint;
      settings +=',left='+winl;
      settings +=',scrollbars=auto';
      settings +=',resizable=yes';
  var win=window.open(mypage,"nw6",settings);
  win.focus();
}

// Ahora con scroll...

function popScrollWin(mypage,w,h){
  var winl = (screen.width-w)/2;
  var wint = (screen.height-h)/2;
  var settings  ='height='+h;
      settings +=',width='+w;
      settings +=',top='+wint;
      settings +=',left='+winl;
      settings +=',scrollbars=yes';
      settings +=',resizable=yes';
  var win=window.open(mypage,"nw",settings);
  win.focus();
}

function popScrollWin2(mypage,w,h){
  var winl = (screen.width-w)/2;
  var wint = (screen.height-h)/2;
  var settings  ='height='+h;
      settings +=',width='+w;
      settings +=',top='+wint;
      settings +=',left='+winl;
      settings +=',scrollbars=yes';
      settings +=',resizable=yes';
  var win=window.open(mypage,"nw2",settings);
  win.focus();
}

function popScrollWin3(mypage,w,h){
  var winl = (screen.width-w)/2;
  var wint = (screen.height-h)/2;
  var settings  ='height='+h;
      settings +=',width='+w;
      settings +=',top='+wint;
      settings +=',left='+winl;
      settings +=',scrollbars=yes';
      settings +=',resizable=yes';
  var win=window.open(mypage,"nw3",settings);
  win.focus();
}

function popScrollWin4(mypage,w,h){
  var winl = (screen.width-w)/2;
  var wint = (screen.height-h)/2;
  var settings  ='height='+h;
      settings +=',width='+w;
      settings +=',top='+wint;
      settings +=',left='+winl;
      settings +=',scrollbars=yes';
      settings +=',resizable=yes';
  var win=window.open(mypage,"nw4",settings);
  win.focus();
}

function popScrollWin5(mypage,w,h){
  var winl = (screen.width-w)/2;
  var wint = (screen.height-h)/2;
  var settings  ='height='+h;
      settings +=',width='+w;
      settings +=',top='+wint;
      settings +=',left='+winl;
      settings +=',scrollbars=yes';
      settings +=',resizable=yes';
  var win=window.open(mypage,"nw5",settings);
  win.focus();
}

function popScrollWin6(mypage,w,h){
  var winl = (screen.width-w)/2;
  var wint = (screen.height-h)/2;
  var settings  ='height='+h;
      settings +=',width='+w;
      settings +=',top='+wint;
      settings +=',left='+winl;
      settings +=',scrollbars=yes';
      settings +=',resizable=yes';
  var win=window.open(mypage,"nw6",settings);
  win.focus();
}


function volverLanzadora(url) {
   window.opener.location.href=url;
   window.self.close();
}

function cerrar() {
   window.self.close();
}