Closed
Bug 138444
Opened 22 years ago
Closed 22 years ago
attribute SELECTED is changed while saving to SELECTED=""
Categories
(Core :: DOM: Serializers, defect)
Tracking
()
People
(Reporter: aha, Assigned: t_mutreja)
Details
(Keywords: testcase)
Attachments
(2 files, 1 obsolete file)
2002041711/RC1/Win2K Repro: 1. open testcase 2. save page as 'Web Page, complete' Actual: OPTION attribute SELECTED is changed while saving to SELECTED="". Expect: Not change attribute, because it's incorrect for HTML4.01.
Reporter | ||
Comment 1•22 years ago
|
||
Comment 2•22 years ago
|
||
Looking for an explanation between the difference between "save as web page HTML only" an and "save as web page complete", but the jist of it is that when saving the complete page the parsed document is saved along with changes that are needed for local viewing. This IS NOT the document byte for byte that was sent to the browser to begin with. Potentially WONTFIX.
Reporter | ||
Comment 4•22 years ago
|
||
I haven't problem with 'browser is changing source-code', but with 'Mozilla turns strictly correct HTML 4.01 code to something incorrect'. Saved page don't validate as HTML 4.01, but original validate.
Comment 5•22 years ago
|
||
This is a document encoder issue.... we should change to SELECTED="SELECTED" To DOM-to-text-conversion
Assignee: law → harishd
Status: UNCONFIRMED → NEW
Component: File Handling → DOM to Text Conversion
Ever confirmed: true
OS: Windows 2000 → All
QA Contact: sairuh → sujay
Assignee | ||
Comment 7•22 years ago
|
||
In mozilla/content/base/src/nsHTMLContentSerializer.cpp, method(line# 314) void nsHTMLContentSerializer::SerializeAttributes(nsIContent* aContent, nsIAtom* aTagName, nsAString& aStr) adding the following at line#361, as an extra condition solves this problem: if ((attrName.get() == nsHTMLAtoms::selected) && valueStr.IsEmpty()){ valueStr = NS_LITERAL_STRING("selected"); } For more clarity, next I'm attaching a text file that contains the modified method as a whole. I'd be thankful if someone can incorporate this change and provide a proper patch with the diff.
Status: NEW → ASSIGNED
Assignee | ||
Comment 8•22 years ago
|
||
Hmm, I think this is a dupe, and peterv already has a fix. *** This bug has been marked as a duplicate of 88761 ***
Status: ASSIGNED → RESOLVED
Closed: 22 years ago
Resolution: --- → DUPLICATE
You need to log in
before you can comment on or make changes to this bug.
Description
•