function openCenteredWindow(a_str_windowURL, a_str_windowName, a_int_windowWidth, a_int_windowHeight, a_bool_scrollbars, a_bool_resizable, a_bool_menubar, a_bool_toolbar, a_bool_addressbar, a_bool_statusbar, a_bool_fullscreen) {
    var int_windowLeft = (screen.width - a_int_windowWidth) / 2;
    var int_windowTop = (screen.height - a_int_windowHeight) / 2;
    if (a_str_windowName == '') {
        var curdate = new Date();
        a_str_windowName = "window_" + curdate.getHours() + '' + curdate.getMinutes() + '' + curdate.getSeconds() + '' +  curdate.getMilliseconds();
    }
    var str_windowProperties = 'height=' + a_int_windowHeight + ',width=' + a_int_windowWidth + ',top=' + int_windowTop + ',left=' + int_windowLeft + ',scrollbars=' + a_bool_scrollbars + ',resizable=' + a_bool_resizable + ',menubar=' + a_bool_menubar + ',toolbar=' + a_bool_toolbar + ',location=' + a_bool_addressbar + ',statusbar=' + a_bool_statusbar + ',fullscreen=' + a_bool_fullscreen + '';
    var obj_window = window.open(a_str_windowURL, a_str_windowName, str_windowProperties);
    if (parseInt(navigator.appVersion) >= 4) {
        obj_window.window.focus();
    }
}

function zoomImage(myimage) {
 
 html = "<html><head><title>CebuPOT</title>"
  + "</head><body leftmargin=0 " 
  + "marginwidth=0 topmargin=0 marginheight=0><centerR>" 
  + "<img src='" + myimage + "' border=0 name=image " 
  + "onload='window.resizeTo(document.image.width, document.image.height);window.moveTo((screen.width - document.image.width) / 2, (screen.height - document.image.height) / 2);'>"
  + "</center>" 
  + "</body>"
  + "</html>";
 var curdate = new Date();
 windowName = "window_" + curdate.getHours() + '' + curdate.getMinutes() + '' + curdate.getSeconds() + '' +  curdate.getMilliseconds();
 popup=
 window.open
  ('',windowName,
  'toolbar=0,location=0,directories=0,menuBar=0,scrollbars=0,resizable=1');
 popup.document.open();
 popup.document.write(html);
 popup.document.focus();
 popup.document.close()
 };



