Results 1 to 3 of 3

Thread: Hot Keys with en embedded frame target

  1. #1
    Join Date
    Sep 2005
    Posts
    2
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default Hot Keys with en embedded frame target

    http://www.dynamicdrive.com/dynamicindex5/button1.htm

    I'm using the script that now supports Mozilla Fire Fox 1.0. I would like to have the Hot Keys target an embedded frame in the page instead of the replacing the entire page?

  2. #2
    Join Date
    Mar 2005
    Location
    SE PA USA
    Posts
    30,495
    Thanks
    82
    Thanked 3,449 Times in 3,410 Posts
    Blog Entries
    12

    Default

    Just change each occurrence of:
    Code:
    window.location=dest[i]
    to:
    Code:
    document.frame1.location.href=dest[i]
    where 'frame1' is the name of your iframe or frame:
    HTML Code:
    <iframe name="frame1"></iframe>
    - John
    ________________________

    Show Additional Thanks: International Rescue Committee - Donate or: The Ocean Conservancy - Donate or: PayPal - Donate

  3. #3
    Join Date
    Sep 2005
    Posts
    2
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default Tried your suggestion

    Your suggestion was simple enough, but when I made the change the hot keys stopped working all together?

    I edited the code from:

    document.frame1.location.href=dest[i]

    to

    window.frame1.location.href=dest[i]

    Now it works. Thanks, for the help.

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •