    
   function popWindow(typ,n,gates,sz) {
	size = sz + ',resizable'
    	popWnd = window.open('','gates',size)  // IE code
	popWnd.document.clear()
	if (popWnd.screen) {
  	    popWnd.moveTo(0,0);
    	    popWnd.outerHeight = screen.availHeight;
   	    popWnd.outerWidth  = screen.availWidth;
	}
	flw  =  "<br><br><br>T<br>h<br>e<br><br><br><br>G<br>a<br>t<br>e<br>s<br><br><br><br><br>1<br>9<br>7<br>9<br><br><br><br><br>to<br><br><br>2<br>0<br>0<br>5"
	flw +=	"</a></td>\n"
	flw_h = "The Gates &nbsp;&nbsp; Christo & Jeanne-Claude &nbsp;1979 - 2005"
	fnt  =  "<font  face='Gothic' size=1 color='#404040'>"
	fntl =  "<font  face='Gothic' size=1  color='#FFA70B'>"
	pic  =  "images/gates/" + n + "b.jpg"
	
	popPgm  = "\n\n"
	popPgm += "<HTML><HEAD><TITLE>2005/02 The Gates</TITLE></HEAD>\n"
	popPgm += "<SCRIPT language=\"JavaScript\" src=\"gates.js\"></SCRIPT>\n"
	popPgm += "<BODY bgcolor='#8D99CB' link='#FFA70B' topmargin=0 leftmargin=0 marginheight=0 marginwidth=0><center>"
	popPgm += "<table border=0 cellpadding=0 height=100% width=100%>\n"
	popPgm += "<tr valign=center><td align=center>\n"
	popPgm += "<table border=1 cellpadding=4 cellspacing=1 bordercolordark=gray bordercolorlight=silver>\n"
	if(typ == 1) { // 21-25 A
	    popPgm += "<tr><td align=center><a HREF=\"javascript:window.close()\">"
	    popPgm += fntl + "e x i t</a>"
	    popPgm += "</td><td colspan=3 align=center>\n" + fnt + flw_h
	    popPgm += "</td><td colspan=1 align=center>\n"
	    popPgm += "<a HREF=\"javascript:popWindow(5,16,'gates','" + sz + "')\">"
	    popPgm +=  fntl + "m o r e . .</a></td>" 
	    popPgm += "<tr><td colspan=5>"
	    popPgm += "<img src='" + pic + "' border=0></td></tr><tr valign=top>\n"
	    for(var i=21;i<=25;i++) {
		lnk = makeLink(typ,i,gates,sz)
		popPgm +=  lnk
            }
	}
	if(typ == 2) { // 11-15 C
	    popPgm += "<tr><td colspan=5>"
	    popPgm += "<img src='" + pic + "' border=0></td></tr><tr valign=top>\n"
	    for(var i=11;i<=15;i++) {
		lnk = makeLink(typ,i,gates,sz)
		popPgm +=  lnk
            }
	    popPgm += "<tr><td colspan=1 align=center>\n"
	    popPgm += "<a HREF=\"javascript:popWindow(5,20,'gates','" + sz + "')\">"
	    popPgm +=  fntl +" . . b a c k </A></td>"
	    popPgm += "</td><td colspan=3 align=center>\n" + fnt + flw_h
	    popPgm += "</td><td colspan=1 align=center>\n"
	    popPgm += "<a HREF=\"javascript:popWindow(4,1,'gates','" + sz + "')\">"
	    popPgm +=  fntl +"m o r e . .</A></td>" 
	}
	if(typ == 3) { // 6-10 E
	    popPgm += "<tr colspan=2><td rowspan=5>"
	    popPgm += "<img src='" + pic + "' border=0></td>"
	    t0 = ""
	    t1 = "<td rowspan=4 valign=center align=center>" + fnt + flw 
	    for(var i=6;i<=10;i++) {
		lnk = makeLink(typ,i,gates,sz)
		popPgm +=  t0 + lnk  + t1
		t0 = "</tr><tr>"
		t1 = ""
            }
	    popPgm += "<td align=center><a HREF=\"javascript:popWindow(4,5,'gates','" + sz + "')\">"
	    popPgm += fntl + "b<br>a<br>c <br>k<br></a></td>\n"
	}
	if(typ == 4) { // 1-5 D
	    popPgm += "<tr><td colspan=5>"
	    popPgm += "<img src='" + pic + "' border=0></td></tr><tr valign=top>\n"
	    for(var i=1;i<=5;i++) {
		lnk = makeLink(typ,i,gates,sz)
		popPgm +=  lnk
            }
	    popPgm += "<tr><td colspan=1 align=center>\n"
	    popPgm += "<a HREF=\"javascript:popWindow(2,15,'gates','" + sz + "')\">"
	    popPgm +=  fntl +" . . b a c k </A></td>"
	    popPgm += "</td><td colspan=3 align=center>\n" + fnt + flw_h
	    popPgm += "</td><td colspan=1 align=center>\n"
	    popPgm += "<a HREF=\"javascript:popWindow(3,6,'gates','" + sz + "')\">"
	    popPgm +=  fntl +"m o r e . .</A></td>" 
	}
	if(typ == 5) {  // 16-20 B
	    popPgm += "<tr><td colspan=5>"
	    popPgm += "<img src='" + pic + "' border=0></td></tr><tr valign=top>\n"
	    for(var i=16;i<=20;i++) {
		lnk = makeLink(typ,i,gates,sz)
		popPgm +=  lnk
            }
	    popPgm += "<tr><td colspan=1 align=center>\n"
	    popPgm += "<a HREF=\"javascript:popWindow(1,25,'gates','" + sz + "')\">"
	    popPgm +=  fntl +" . . b a c k </A></td>"
	    popPgm += "</td><td colspan=3 align=center>\n" + fnt + flw_h
	    popPgm += "</td><td colspan=1 align=center>\n"
	    popPgm += "<a HREF=\"javascript:popWindow(2,11,'gates','" + sz + "')\">"
	    popPgm +=  fntl +"m o r e . .</A></td>" 
	}

	popPgm += "</tr></table>\n"
	popPgm += "</td></tr></table></center></BODY></HTML>\n"

	popWnd.document.write(popPgm)
	popWnd.document.close()
	popWnd.focus()
    }

    function makeLink(tp,n,gates,sz) {
	picLink  = "<img src='images/gates/" + n + ".jpg' border=0></a></td>\n"
	urlLink  = "<td align=center valign=center>"
	urlLink += "<a HREF=\"javascript:popWindow(" + tp + "," + n + ",'gates','" + sz + "')\">"

	return( urlLink + picLink )
    }
