Bob wrote:
Hello,
The following function is failing in ie7. Can anyone offer a solution?
You have not given a context in which you are trying to achieve with
the code given.
function pause(numberMillis) {
if (IEVERSION >= 5.5) {
How are you obtaining the version number? Is it even reliable?
var dialogScript = 'window.setTimeout(function () {
window.close(); }, ' + numberMillis + ');';
var result =
window.showModalDialog('javascript:document.writel n("<script>'+dialogScript+'</script>")');
Generally good practice to place a type attribute:
<script type = "text/javascript">
The string '</script>' is causing the browser to think that this is
where the script actually ends. Escape the slash:
<\/script>