Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Detecting Vista IE7 Protected Mode with Javascript

I'd like to be able to detect Vista IE7 Protected Mode within a page using javascript, preferably. My thinking is to perform an action that would violate protected mode, thus exposing it. The goal is to give appropriate site help messaging to IE7 Vista users.

like image 299
jdev Avatar asked Dec 02 '08 18:12

jdev


1 Answers

What are you trying to accomplish that is substantially different for protected users? I've seen some window popup issues, but otherwise, clean JavaScript tends to be less affected. If you're finding that a block of code won't execute, why not do a check after attempted execution to see if the document is the state you expect, and alert if not.

If it's it using ActiveX, MS has a Protected Mode API: http://msdn.microsoft.com/en-us/library/ms537316.aspx

Protected mode is customizable, so you don't really have a reliable way of detecting it based on action violation. And many users disable UAC, so detecting via version won't work either (not to mention you may have the same headache with IE 8. Always best to test if something worked instead of assume by version.)

like image 121
user42608 Avatar answered Oct 16 '22 15:10

user42608