javascript in php page to use window.open()

From: Date: Thu, 12 Jan 2006 04:51:01 +0000
Subject: javascript in php page to use window.open()
Groups: php.general 
Request: Send a blank email to php-general+get-228510@lists.php.net to get a copy of this message
Hi everyone, I am trying to open a new window after a successful function call (I don't want to use <a href. and onclick). Here's what I have, but for some reason, in IE the new window does not open (I have popup blockers disabled). It opens in Mozilla, but with the wrong size. What am I doing wrong here? if (insert($lname, $fname, $course, $date, $media1, $media2)) { echo "<script type=\"text/javascript\">\n"; echo " window.open(\"add.html\",\"resizable=no,width=400,height=200\");"; echo "</script>\n\n"; } else echo "Error adding a record."; Thanks. Olga

« previous php.general (#228510) next »