Ho risolto il "problema", così:

function viewFoto(img){
largh=foto1.width+20;
altez=foto1.height+25;
toptop=(screen.height/2)-(altez/2);
leftleft=(screen.width/2)-(largh/2);

stringa="width="+largh+",height="+altez,"top=900,l eft=9000";

finestra=window.open("","displayWindow",stringa)

finestra.document.write ("<html>")
finestra.document.write ("<HEAD><TITLE>Titolo della finestra</TITLE></HEAD>")
finestra.document.write ("<body style=cursor:hand; onClick=self.close();>")
finestra.document.write ("[img]" + img + "[/img]");
finestra.document.write ("</html>")
finestra.document.write ("</body>")
}

Ciao....