Bug 12732

Summary: REGRESSION: Comments fields on ircimages not showing up in nightly
Product: WebKit Reporter: Jarvis Badgley <chiper>
Component: Page LoadingAssignee: Nobody <webkit-unassigned>
Status: RESOLVED FIXED    
Severity: Normal CC: ap, KwhiteRight
Priority: P1 Keywords: InRadar, NeedsReduction, Regression
Version: 420+   
Hardware: Mac   
OS: OS X 10.4   
URL: http://ircimages.com

Description Jarvis Badgley 2007-02-10 21:33:24 PST
I hit up ircimages.com tonight for the first time in the latest webkit build, just to see how well it ran (it's kinda sluggish in FF).  I noticed immediately that only the first image would display the comments field.  I checked in both FF and the latest release of Safari and this problem does not occur in them, just in the webkit nightly.

I suspect this is either JavaScript or iframe related, but I'm not sure how ircimages handles their frame creation.

A bit of warning to testers, ircimages is not work safe.
Comment 1 David Kilzer (:ddkilzer) 2007-02-10 22:30:45 PST
Works with shipping Safari 2.0.4 (419.3) on Mac OS X 10.4.8 (8L127).  Does not work with a local debug build of WebKit r19554 with the same software.

The comments that aren't showing up are <iframe> elements.

Comment 2 Mark Rowe (bdash) 2007-02-12 21:07:52 PST
<rdar://problem/4993463>
Comment 3 Alexey Proskuryakov 2007-02-24 07:41:22 PST
This site loads its content in a quite interesting way:

1) HTML markup is retrieved via XMLHttpRequest;
2) then it is assigned via innerHTML to a temporary display:none div;
3) the div's innerHTML is taken back;
4) the div is cleared;
5) the content is finally written in place - again, via innerHTML.

  This is repeated for several parts of the page, but the main part (with images and comment subframes) is all loaded in a single request. So subframe loading is initiated in step 2, to be immediately canceled in step 4. This confuses WebKit page loading machinery.

    this.getBrowserHTML = function (html)
    {
      tmpXajax = this.$(this.workId);
      if (!tmpXajax)
        {
          tmpXajax = document.createElement("div");
          tmpXajax.setAttribute("id", this.workId);
          tmpXajax.style.display = "none";
          tmpXajax.style.visibility = "hidden";
          document.body.appendChild(tmpXajax);
        }
      tmpXajax.innerHTML = html;
      var browserHTML = tmpXajax.innerHTML;
      tmpXajax.innerHTML = "";
      return browserHTML;
    };
Comment 4 Anders Carlsson 2007-07-17 20:49:07 PDT
Committed revision 24396.