// JavaScript Document

var newwindow;
var wheight = 0, wwidth = 0;

function popitup(url, iwidth, iheight) {
var title='~&nbsp; c &nbsp; a &nbsp; n &nbsp; i &nbsp; n &nbsp; a &nbsp;~';
var pwidth, pheight;

if ( !newwindow || newwindow.closed ) {
pwidth=iwidth+30;
pheight=iheight+30;
newwindow=window.open('','htmlname','toolbar=no,menubar=no,status=no,location=no,width=' + pwidth + ',height=' + pheight + ',top=50,left=10');
wheight=iheight;
wwidth=iwidth;
}

if (wheight!=iheight || wwidth!=iwidth ) {
pwidth=iwidth+30;
pheight=iheight+90;
newwindow.resizeTo(pwidth, pheight);
wheight=iheight;
wwidth=iwidth;
}

newwindow.document.clear();
newwindow.focus();
newwindow.document.writeln('<html> <head> <title>' + title + '</title> <\/head> <body bgcolor= \"#F0E3B9\"> <center>');
newwindow.document.writeln('<img src=' + url + ' title=\"' + title + '\" alt=\"\">');
newwindow.document.writeln('<\/center> <\/body> <\/html>');
newwindow.document.close();
newwindow.focus();
}

// Function to close all popup windows when page is left
// Call with an onUnload="closePopups()" in <body> tag

function closePopups() {
if (newwindow && !newwindow.closed) { newwindow.close(); }
}