var win = null;

function PopupWindow(mypage,myname,w,h,scroll)
{
  var winl = (screen.width-w)/2;
  var wint = (screen.height-h)/2;

  settings = 'height='+h+',width='+w+',top='+wint+',left='+winl+',scrollbars='+scroll+',toolbar=no,location=no,status=no,menubar=no,resizable=no,dependent=no';

  win=window.open(mypage,myname,settings)
  if(parseInt(navigator.appVersion) >= 4)
  {
    win.window.focus();
  }
}

function PopupWindowWall(mypage,myname)
{
  click='http://www.walls.ru/php/show.php?imgid=2597&des=white&resw='+screen.width+'&resh='+screen.height;
  click=mypage;

  var winwidth = screen.availWidth;
  var winheight = screen.availHeight;

  if (document.all)
  {
    var sizer = window.open('','','left=0,top=0,width=winwidth,height=winheight, scrollbars=yes ,fullscreen=yes');
    sizer.location = click;
  }
  else
  {
    window.open(click,'img','width=winwidth, height=winheight, menubar=no, status=no, scrollbars=yes, location=no, fullscreen=yes, directories=no, resizable=yes');
  }
}
