Bug 375999 - [test case] form siblings bug afecting all jquery 3 web sites
Summary: [test case] form siblings bug afecting all jquery 3 web sites
Status: RESOLVED UNMAINTAINED
Alias: None
Product: konqueror
Classification: Applications
Component: khtml ecma (show other bugs)
Version: 4.14.2
Platform: Gentoo Packages Linux
: NOR major
Target Milestone: ---
Assignee: Konqueror Developers
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2017-02-04 13:31 UTC by Anguo
Modified: 2024-05-06 20:51 UTC (History)
1 user (show)

See Also:
Latest Commit:
Version Fixed In:
Sentry Crash Report:


Attachments
Failing this simple test case prevents jquery 3 from working in konqueror (1.06 KB, text/html)
2017-02-04 13:31 UTC, Anguo
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Anguo 2017-02-04 13:31:10 UTC
Created attachment 103819 [details]
Failing this simple test case prevents jquery 3 from working in konqueror

I was trying to debug why one web site using jquery 3 was working in every browser I tried but in konqueror. 
As I tried to narrow down the problem,  I found that jquery 3 contains the following code, which, if removed, fixed the symptoms in konqueror:


// Support: Safari 8 only
// In Safari 8 documents created via document.implementation.createHTMLDocument
// collapse sibling forms: the second one becomes a child of the first one.
// Because of that, this security measure has to be disabled in Safari 8.
// https://bugs.webkit.org/show_bug.cgi?id=137337
support.createHTMLDocument = ( function() {                                                                                                                                 
        var body = document.implementation.createHTMLDocument( "" ).body;
        body.innerHTML = "<form></form><form></form>";
        return body.childNodes.length === 2;
} )();


Following the webkit bug report referred in the jquery code, I found the test case which I attach here. 
Today, the test case works in Firefox, etc, but does not render anything in Konqueror.

This is a pretty major bug: I don't need to tell you how many web sites out there use jquery. I don't know if the symptomatic code is in jquery 2, but it certainly is in jquery 3, which is gaining wide adoption. And as I said, I found this while trying to find out why a web site using jquery was broken and unusable in konqueror.
Comment 1 Anguo 2017-02-04 13:35:47 UTC
I am currently using Konqueror Version 4.14.24 within gentoo.
I wouldn't know where to begin to fix this bug, but if I can help you with testing, compiling from the latest version in git, etc., just let me know how I can help.
Comment 2 Christoph Cullmann 2024-05-06 20:51:20 UTC
Dear user,

KHTML (and KJS) was a long time more or less unmaintained and got removed in KF6.

Please migrate to use a QWebEngine based HTML component.

We will do no further fixes or improvements to the KF5 branches of these components beside important security fixes.

For security issues, please see:

https://kde.org/info/security/

Sorry that we did not fix this issue during the life-time of KHTML.

Greetings
Christoph Cullmann