WebKit Bugzilla
New
Browse
Log In
×
Sign in with GitHub
or
Remember my login
Create Account
·
Forgot Password
Forgotten password account recovery
RESOLVED FIXED
Bug 9901
XSLTProcessor cannot parse text nodes for INPUT ELEMENTS in an XSLT stylesheet
https://bugs.webkit.org/show_bug.cgi?id=9901
Summary
XSLTProcessor cannot parse text nodes for INPUT ELEMENTS in an XSLT stylesheet
JB Smith
Reported
2006-07-13 14:37:48 PDT
If XSLTProcessor is given a stylesheet that would generate text nodes for an INPUT ELEMENT, it fails with no error thrown.
Attachments
testcase9901.dmg
(78.02 KB, application/octet-stream)
2006-07-14 16:42 PDT
,
JB Smith
no flags
Details
more reduced test
(1.68 KB, application/zip)
2006-07-26 09:42 PDT
,
Alexey Proskuryakov
no flags
Details
proposed fix
(3.94 KB, patch)
2006-07-26 13:22 PDT
,
Alexey Proskuryakov
darin
: review+
Details
Formatted Diff
Diff
Show Obsolete
(1)
View All
Add attachment
proposed patch, testcase, etc.
Alexey Proskuryakov
Comment 1
2006-07-14 14:21:10 PDT
This needs a test case.
JB Smith
Comment 2
2006-07-14 16:42:56 PDT
Created
attachment 9455
[details]
testcase9901.dmg Attached is a complete testcase reduction for this particular BUG. Copy the contained tescase9901 folder into a test webserver's content directory and browse to it to get started.
Alexey Proskuryakov
Comment 3
2006-07-25 14:09:02 PDT
The stylesheet fails to load: <?xml version="1.0" encoding="UTF-8"?> <xsl:stylesheet xmlns:xsl="
http://www.w3.org/1999/XSL/Transform
" version="2.0" xmlns="
http://www.w3.org/1999/xhtml
"> <xsl:output encoding="ISO-8859-1" omit-xml-declaration="no" method="html" indent="yes"/> ... <input name="e164_id" class="item" readonly="readonly" type="text" id="country.e164_id" value="{$e164_id}">textnode_that_will_fail</input> As far as I can tell, xmlns="
http://www.w3.org/1999/xhtml
" has no business being here, and removing it (or even changing to xmlns="aaa") fixes the symptom. But I do not see why it has such an effect (of course, the <input> element should be empty in XHTML, but that doesn't explain the behavior IMHO).
Alexey Proskuryakov
Comment 4
2006-07-26 09:42:13 PDT
Created
attachment 9699
[details]
more reduced test
Alexey Proskuryakov
Comment 5
2006-07-26 13:22:16 PDT
Created
attachment 9702
[details]
proposed fix Make sure to write a closing tag if an element has child nodes, to make the output valid XML. We don't care that HTML may forbid the closing tag if the element in question has child nodes. It's a bit surprising that XSLTProcessor goes from DOM to XML document via a serialized representation (though this helped to find this bug :) ).
Darin Adler
Comment 6
2006-07-26 13:50:05 PDT
Comment on
attachment 9702
[details]
proposed fix r=me
Alexey Proskuryakov
Comment 7
2006-07-26 21:25:38 PDT
Committed revision 15645.
Note
You need to
log in
before you can comment on or make changes to this bug.
Top of Page
Format For Printing
XML
Clone This Bug