Bug 137337 - REGRESSION (iOS 8): When constructing a new document that has sibling forms, the second form ends up being a child of the first form
Summary: REGRESSION (iOS 8): When constructing a new document that has sibling forms, ...
Status: RESOLVED DUPLICATE of bug 139561
Alias: None
Product: WebKit
Classification: Unclassified
Component: HTML DOM (show other bugs)
Version: 528+ (Nightly build)
Hardware: iPhone / iPad Other
: P2 Major
Assignee: Nobody
URL:
Keywords: InRadar
Depends on:
Blocks:
 
Reported: 2014-10-02 01:29 PDT by Shawn Jansepar
Modified: 2014-12-11 16:04 PST (History)
9 users (show)

See Also:


Attachments
Minimal test case (1.06 KB, text/html)
2014-10-02 01:29 PDT, Shawn Jansepar
no flags Details

Note You need to log in before you can comment on or make changes to this bug.
Description Shawn Jansepar 2014-10-02 01:29:04 PDT
Summary:
When constructing a new document using document.implementation.createHTMLDocument and setting innerHTML of the body of that new document with a string of HTML content that has sibling forms, the second form ends up being a child of the first form. This is something I've only ever encountered on iOS8 Safari (has been tested all the way down to iOS4.2, Android 2.1, Firefox 4, etc without any issue).

Steps to Reproduce:
1. Grab minimal test case and run it on iOS8.0.(0|1|2)
2. Note that the document isn't correctly constructed, as the second form ends up becoming a child of the first form.

Expected Results:
The document created from the string should have forms as siblings of one and other.

Actual Results:
The document isn't correctly constructed, as the second form ends up becoming a child of the first form.

Version:
iOS8 (12A365) and newer

A minimal test case is attached.
Comment 1 Shawn Jansepar 2014-10-02 01:29:38 PDT
Created attachment 239090 [details]
Minimal test case
Comment 2 Radar WebKit Bug Importer 2014-10-02 23:20:43 PDT
<rdar://problem/18535909>
Comment 3 Michał Gołębiowski-Owczarek 2014-12-10 02:09:12 PST
This broke a security-related patch in jQuery:
https://github.com/jquery/jquery/pull/1505

We had to back it out because it broke Safari 8.
Comment 4 Benjamin Poulain 2014-12-11 16:04:28 PST
This looks  like https://bugs.webkit.org/show_bug.cgi?id=139561

*** This bug has been marked as a duplicate of bug 139561 ***