I'm afraid the two former answers are quite right. You handle windows in JavaScript - not in PHP. PHP is serverside, and can in principle only deliver HTML to a single - already open - window, while JavaScript is clientside and can open (and close, and juggle) as many windows as you machine can handle.
Look for window.open() in any JS manual.
Martin