...

View Full Version : Urgent! IE JavaScript Password Problem



Staccs
06-09-2010, 07:19 AM
I'm having trouble with a Javascript pop up box not appearing on Internet Explorer. I have tested it with IE7 and IE8 with no success. It works on Firefox 3.6.3 and Opera.

On internet explorer this yellow bar appears;
http://i46.tinypic.com/282fhqr.png

However, once clicked and given temporary permission the page reloads not showing the pop up box and the yellow bar is still present.

I have re-created the situation here;
http://html.comuf.com/

problem.html is the page I need help on. The correct password is real which redirects you to real.html.

I am open to using new scripts but this line/function is crucial;

location.href= password + ".html";

This problem is for a friend of mine who does design work, his client is having trouble with this. The pop up box must appear after allowed temp through IE, or even better no user allowance is required while keeping the password +.html code.

P.S. I plan to stick around and learn after this gets answered!

jmrker
06-09-2010, 03:59 PM
If this is a local script, then the message, I believe, is normal until you change the security settings on your computer.
Probably will go away if the script is on a server.

Staccs
06-09-2010, 05:38 PM
Hi,

Thanks for the response.

It is not a local script. The message is due to security settings on the user computer though. However, once the user clicks the info bar and allows the script to run it does not run and the info bar comes up again.

Cant this be fixed? Is there a better alternative?

mrhoo
06-09-2010, 06:20 PM
There is an explanation and possible solution for dealing with IE7 and 8 security blocking of user input in prompts and such here-

http://pipwerks.com/2007/08/08/a-cross-browser-javascript-prompt/


window.showModalDialog is also supported in recent versions of Firefox, Chrome, Safai and Opera

Staccs
06-09-2010, 07:30 PM
There is an explanation and possible solution for dealing with IE7 and 8 security blocking of user input in prompts and such here-

http://pipwerks.com/2007/08/08/a-cross-browser-javascript-prompt/


window.showModalDialog is also supported in recent versions of Firefox, Chrome, Safai and Opera

Thank you very much. I am reading it over for the second time - but I'm not sure if I understand coding enough to implement this. Where do I put

location.href= password + ".html";?

Thanks again, I hope to answer my own question.

Staccs
06-09-2010, 07:58 PM
Got it working, then tested it in IE. IE blocks it. And again, even after allowing it doesn't working. I'm thinking I should just try and do it without a popup. Not sure why a pop up is needed anways... Any help is appreciated.



EZ Archive Ads Plugin for vBulletin Copyright 2006 Computer Help Forum