   var mywindow;
   var features='width=360,height=580,top=0,left=0,resizable';

window.onload=function(){
   var anc=document.getElementsByTagName('a');
for(var c=0;c<anc.length;c++) {
 /* this line looks for links with the attribute class="pu" and then opens a pop-up onclick */
if(anc[c].className=='popup') {
   anc[c].onclick=function() {
   createPopUp(this);
   return false;
    }
   }
  }
 }

function createPopUp(url) {
if(mywindow) {
   mywindow.close();
 }
   mywindow=window.open(url,'myExample6',features);
   mywindow.focus();
 }
