|
Posted by gleverett on 09/19/05 23:11
I have been searching the 'Net, and I can't find the right solution
here. I am writing some PHP pages that utilize some Javascript. The
script works in Mozilla/Netscape, but fails in IE. I don't know if
it's the Javascript or the PHP that is causing the problem. I started
with an example in a book and added on.
The script I'm using is:
<SCRIPT LANGUAGE="Javascript" TYPE="text/javascript">
<!--
function open_window(url) {
var NEW_WIN = null;
NEW_WIN = window.open ("", "Record Viewer", "toolbar=no,width=<?php
echo $new_win_width ?>,height=<?php echo new_win_height
?>,directories=no,status=no,scrollbars=yes,resizable=yes,menubar=no");
NEW_WIN.location.href = url;
}
//-->
</SCRIPT>
(I added some line break to make it readable The NEW_WIN line is all
on one line.)
The PHP variables get added correctly, and the two calls from the PHP
program are similar to:
<a
href="javascript:open_window('$PHP_SELF?action=action1');\">Action1</a>
or an
echo "<button
onClick=\"javascript:open_window('$PHP_SELF?action=insert_record');\" >
Insert new record</button>";
These work fine in Netscape/Mozilla, but in IE, after clickng a bunch
of times, I get "Domain not found". I've replaced PHP_SELF with the
full URL to test, and it still fails. I know that the scripting is
turned on in IE becuase I can go to example sites and the window.open
function works.
Any ideas as to what's going on here?
Navigation:
[Reply to this message]
|