PDA

View Full Version : How to target frames with Encrypted password script?



needhelp123
05-08-2008, 05:13 AM
1) Script Title:
Encrypted Password script
2) Script URL (on DD):
http://www.dynamicdrive.com/dynamicindex9/password.htm
3) Describe problem:
The script itself works, but how do I target it to a specific frame? For example, my website has 3 frames within the frameset. The script is currently running in the 'topFrame', so everytime I login, it automatically opens the webpage inside the 'topFrame'. However, I want it to open the webpage inside the 'mainFrame'. How would I go about modifying it so that it can target frames? I've tried things such as, target="mainFrame", but that hasn't been any help. Any help is appreciated. :)

jscheuer1
05-08-2008, 08:53 AM
Replace:


window.location=password+".htm"}

with:


top.frames['mainFrame'].location.href=password+".htm"}