Need help on Javascript...

ok… i’m making a website for a teacher, and there’s this page where a popup window opens as soon as the page is loaded, to show a picture. However, i want the poped up window to close automatically as soon as i leave that page… does anyone know how i can go about to do that?

following is part of the html javascript code that is used to open the popup window… this is located in the Head /head part of the page.

"SCRIPT LANGUAGE=‘JavaScript’ "
"!-- Screening out old browsers

var newwindow;

newwindow=window.open ('crenard12.jpg', 'Picture', 'height=400, width=500,resizeable=yes,left=200,top=200');
if (window.focus) {newwindow.focus()}

"// End screening
–>

“/Script”

PS… i have to replace the <>s with "s, because the forums thingy thought it was html code… which it is…but it wasnt intended for this…

Never mind…

i figured out a sorta-solution… it’s prolly as good as it’s gonna get for now… i still have homework to do… blah…

THANKS A BUNCH, GUYS!!! :stuck_out_tongue:

<>

[edit]wierd, seems to work for me.

Oh, I see. Putting text in between is what screws the pooch. Padding the text with spaces might work.

< maybe >