views:

143

answers:

1

I have two html files, but contains javascript. But wired enough, when I open one of them the ie7 displays it w/o any warning but the 2nd one always shows the warning message saying this file contains ActiveX/javascript bla, bla.

I compare those two files, no difference. Anybody gets any clue?

Thanks in advance!

+1  A: 

Are you loading them directly from your hard disk, rather than via a web server? Perhaps one of them contains the Mark Of The Web and the other doesn't?

"The MOTW is a comment added to the HTML markup for a Web page. When a user opens the Web page from their local machine, Internet Explorer references this comment to determine the security zone in which it should run the page."

RichieHindle
I open them by double clicking the files. This problem bothers me so much that I even copied the contents from good one into the bad one to make sure they have exactly the same contents. But still the same result: one shows warning, the other not.I guess, it must relate to the file security issue, not just contents of file...
jeffu
If you Right-click the files and go Properties, does the "General" tab say at the bottom "This file came from another computer [...]" with an "Unblock" button? I've seen that for executables - perhaps there's something similar for HTML files?
RichieHindle
Yes, the one that NOT showing the warning is associating with the "Unlock" button, the other one doesn't. This could be the reason, but how to make the one with warning to have the unlock button link?
jeffu
It sounds like the Unblock thing is effectively the same as Mark Of The Web - if you add a Mark Of The Web to the one that's giving the warning, does that make the warning go away?
RichieHindle
Yes, "Unblock" removes the MOTW from the NTFS alternate data stream on the file.
EricLaw -MSFT-