WebKit Bugzilla
New
Browse
Log In
×
Sign in with GitHub
or
Remember my login
Create Account
·
Forgot Password
Forgotten password account recovery
RESOLVED INVALID
40619
HTML DOM entities are not encoded(escaped) as expected
https://bugs.webkit.org/show_bug.cgi?id=40619
Summary
HTML DOM entities are not encoded(escaped) as expected
kokilakr@gmail.com
Reported
2010-06-15 04:49:36 PDT
Using javascript innerHTML or OuterHTML from DOM returns the decoded HTML entity. Example <div id='id1'>sample © text</div> decodes the © and is returned. Whereas few of the entities like & are properly encoded. Expected result: The entities should not be decoded.
Attachments
Add attachment
proposed patch, testcase, etc.
Alexey Proskuryakov
Comment 1
2010-06-15 10:40:42 PDT
Why do you expect this? It's not how any browser works to the best of my knowledge. More specifically, implementing that would involve preserving entity nodes in DOM, which would be incompatible with other browsers and slow. If you have a test case that works in other browser engines, but not in WebKit, please attach it.
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