IE8 security block (?) for window popup with document.write

I've got one single user (out of thousands) that cannot use the following html/javascript.
The small popup window displays "page cannot be found".

They (the IS dpt) cannot find any security setting in the user computer that might be affecting this, and all the collegues' are having no problem.
To fix this, they just gave the user a new computer (should be upgraded anyway), but unfortunately(?) they in some way transferred the IE settings from the old computer to the new one.

Does there exist some setting that would block the technique used below? (the web site is on the internet zone)

The idea of the code is of course that when clicking "Open test window", a small window shall open which contains the text "Test in a small window"
This user just gets "the page cannot be found"
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Frameset//EN" "">
Beginning of test page
<script language=JavaScript><!--
function Test(funcarg)
  var win =, 'Test', 'width=400,height=500,scrollbars=yes,resizable=yes');
    alert('Error: no win');
  else {
    var doc ='text/html', 'replace');
      alert('Error: no doc');
    else {
      doc.write('<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Frameset//EN" "">\n');
      doc.write('Test in a small window\n');
<option value="" selected>
<option Abc>One Abc choice
<a href="javascript:Test();">(Open test window)</a></span>
End of test page

Open in new window

Stefan LennerbrantAsked:
Who is Participating?
I don't see anything that says null is valid.

According to w3schools, it is not valid.

I've run some searches on Google but have not been able to find any results that include passing null as the URL.
Stefan LennerbrantAuthor Commented:
Hmm, maybe I should have been using'', 'Test', ...) instead of, 'Test', ...)
Or some kind of 'about:' ? Or maybe reference to an actual (but empty) html file
Does that matter? I had the impression that 'null' is ok?
It does not work on my IE8 either.

Setting it to "" (empty string) works, but...
I prefer to open a "blank.html" page (that exists on our production servers) and open that URL.  That way a valid empty page loads (avoids the 'null' issue, and also allows you to open the page as http:// or https:// )
Free Tool: Path Explorer

An intuitive utility to help find the CSS path to UI elements on a webpage. These paths are used frequently in a variety of front-end development and QA automation tasks.

One of a set of tools we're offering as a way of saying thank you for being a part of the community.

Stefan LennerbrantAuthor Commented:
Weel, yeah, I just realized that we normally use '' as URL, instead of null, in most situations. But not in this one.
Hmm, I cannot find any info (in docs) on that null would be a problem, but on the other hand one always refers to using '' in the docs.

It strikes me that we might have had some reason for changing from '' to null in the code -- but I can't remember just now...?

Strange that it didn't work for you, directly. I've really got tens of thousands of users that have no problems at all...

Does anyone know anything about what the difference between null and '' would be, in

I've got a situations with a <frameset> where one <frame> is empty (filled from another by document.write)
There I *need* to use an empty existing html file as URL for the empty frame, otherwise I'll get security issues depending on if the user uses http or https.

If you recall why you wanted to use null, let me know!  I'm curious.
Stefan LennerbrantAuthor Commented:
I will begin checking if switching to '' makes a difference for that particular user.

What a fortune that you ran into "problems" immediately. Hmm, wonder what is needed for IE8 to react like that?

Does anybody (apart from me, my collegues, and many many users) get the original code above to work, which is using 'null'

I blame all of my IE8 issues on this locked down BS version of IE8 that my company provides.  It works fine on my home laptop's IE8.

There are so many items gimped in this version of IE8, that I cannot tell you which of them would be the cause... (for example, it will not let me open new tabs - everything has to be in a new window... how lame is that!)
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.