var flag = 0;
function openPopWindow(theURL,winName,features) {
if(flag){
the_window.close();
}
the_window = window.open(theURL,winName,features);
flag = 1;
}
