...

View Full Version : Javascript not displaying in local files



nathan323
07-11-2011, 08:41 AM
Howdy all.

I have Win 7, IE9.

I have a HTML file on my hard drive, with Javascript within. When I load the page, it keeps popping up Do u want to allow this content, I have to click to allow. I want to stop this, and after doing some searching I found the setting in Internet Options, Advanced - "Allow active content to run in files on my computer".

Perfect.

Doesnt work. When i check this box, the page loads without the warning, but then the Javascript just doesnt work.

Getting quite annoying, because this file is my home page.

Any help would be great!

BulletTimeBill
07-11-2011, 10:14 AM
That's just what IE does. I'm not actually sure if there is a setting to stop it on local machines. Just don't use IE for any sort of development testing...unless your testing to make sure it works in IE :P

nathan323
07-11-2011, 01:03 PM
Ok, so "active content" doesnt refer to Javascript?

When I "Allow active content to run in files on my computer", it directly affects the local page in question - albeit in a strange way, in that it doesnt warn me anymore, but the Javascript doesnt work..

rnd me
07-11-2011, 07:16 PM
rename your html file as .hta and add an application tag as suggested by M$.

nathan323
07-14-2011, 03:54 PM
Ok. Tried that, but it doesnt run in IE? which means i cant browse back & forth, not gonna be any good.

I should mention that neither Java applets or .swf files run in local files either, even though ive just downloaded the latest Java and latest flash player. They work in Firefox though..

rnd me
07-14-2011, 06:58 PM
Ok. Tried that, but it doesnt run in IE? which means i cant browse back & forth, not gonna be any good.


i'm pretty sure forward and back work in HTA's, there's just no buttons by browser displayed by default. hotkeys should still work, as would <button>s than call the javascript nav commands, eg: history.go(-1) ...

jmrker
07-14-2011, 07:48 PM
Post some sample code that does not work for you.
Not everything, just relevant parts.



EZ Archive Ads Plugin for vBulletin Copyright 2006 Computer Help Forum