Results 1 to 2 of 2

Thread: getting an onmouse event working outside an iframe

  1. #1
    Join Date
    May 2011
    Posts
    6
    Thanks
    1
    Thanked 0 Times in 0 Posts

    Question getting an onmouse event working outside an iframe

    Hi all
    I have a test page here I want the onmouse events to appear from the iframe onto the parent page.I found this thread but it doesn't really explain how to implement it. I would appreciate some help please.

    Thanks if you can help.

    Paul

  2. #2
    Join Date
    Sep 2008
    Location
    Midland, Texas
    Posts
    52
    Thanks
    16
    Thanked 0 Times in 0 Posts

    Default

    You can refer to the parent window by using "top" or "parent" for example:

    window.top.document.title;
    window.parent.document.title;
    window.top.location.href = "http://www.newlocationhere.com";
    window.parent.location.href = "http://www.newlocationhere.com";


    will give you the title of the page which contains the frame[s]. So if you need the "onmouse" to trigger an event on the parent or top page you can refer to the method or action by either one of these. Hope this helps.

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
  •