SitePoint Sponsor

User Tag List

Results 1 to 2 of 2
  1. #1
    SitePoint Member
    Join Date
    Apr 2013
    Posts
    2
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    iframe problem with IE and location

    I've been using the following code without problems for the past 5 years or so to check that an iframe has been launched from its parent:

    Code:
    if (top.location == location)
    Suddenly, just in the past couple of days it's stopped working in some versions of IE which I'm guessing might be due to a javascript update that some users of the site have had while others haven't. No problems with Firefox, Chrome, Safari etc.

    Can anyone suggest why

    Code:
      if (top.location == location)
    should no longer function as expected all of a sudden? I've also tried window.top.location and window.location and window.parent.location but it made no difference. I don't run a Microsoft OS myself so at present not sure which of the 2 variables (top.location and location) isn't being determined correctly.

  2. #2
    SitePoint Member
    Join Date
    Apr 2013
    Posts
    2
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Issue now resolved, please ignore.


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
  •