Will The Mark of the Web always ensure IE runs local HTML file

4.6k Views Asked by At

We are distributing a CD that displays our HTML based menu on AutoRun. The menu(a local HTML file) runs in the users browser and communicates information about whats on the CD (a Customisation Package so NOT an installer). Our menu relies heavily on JQuery so not being able to run Javascript is not good. We chose to make the menu in HTML, CSS, Javascript to achieve cross-platform compatibility.

Because we are running a local HTML file that uses Javascript we encounter IE's restriction from running scripts or ActiveX Controls.

Our solution (according to our previous question) is to use The Mark of the Web. But we have one question:

Is this the silver bullet that will overcome IE's restrition?

Will The Mark of the Web work on IE V8 and up? Can I say with certainty that this will overcome IE's restriction or are there other factors I need to consider?

1

There are 1 best solutions below

1
On BEST ANSWER

This does indeed appear to be "The Silver Bullet". One of the reasons to include MOTW, in fact, the first reason is:

  • You are coding pages that will be viewed from a CD, DVD, or other local storage device. (Be aware that users can, but won't necessarily, exempt local content from this security feature.)

The following code causes the file to be run in the Internet zone, which will remove the restrictions placed by IE. Please note that some users settings can prevent this code working, or a user can manually bypass this feature and force the window to run in the normal way which will prevent your JS from working.

<!-- saved from url=(0014)about:internet -->

There is no specifics on where it should be placed appart from The comment must appear in the first 2,048 bytes of the HTML document, within the HTML markup.

As for your question regarding it's compatibility, the feature was introduced in Microsoft Internet Explorer 4.0 and is compatible with every version from there up.