Opened 12 years ago

Closed 12 years ago

Last modified 11 years ago

#4033 closed defect (wontfix)

normalize handling of "value" attribute in the parser

Reported by: bill Owned by: Douglas Hays
Priority: high Milestone: 1.3
Component: Dijit Version: 0.9
Keywords: Cc:
Blocked By: Blocking:

Description

Ideally the parser should differentiate between <input> and <input value="">, as the latter (but not the former) should override a default value defined in the widget's prototype like value:"default".

However, on IE we haven't figured out a way to differentiate these two cases without parsing outerHTML, so maybe it's best to just normalize all browsers to interpret <input> as <input value="">

Attachments (3)

3998.patch (993 bytes) - added by bill 12 years ago.
doug's patch to use outerHTML
parser.html (6.9 KB) - added by bill 12 years ago.
parser test w/test case added for value attribute
4033.patch (1.5 KB) - added by Douglas Hays 12 years ago.
IE patch to parser to parse outerHTML and only process attributres found

Download all attachments as: .zip

Change History (9)

Changed 12 years ago by bill

Attachment: 3998.patch added

doug's patch to use outerHTML

Changed 12 years ago by bill

Attachment: parser.html added

parser test w/test case added for value attribute

comment:1 Changed 12 years ago by bill

(In [10005]) Write total parse time to console. Refs #4033 (lets us try various algorithms and test their performance)

Changed 12 years ago by Douglas Hays

Attachment: 4033.patch added

IE patch to parser to parse outerHTML and only process attributres found

comment:2 Changed 12 years ago by bill

Owner: changed from bill to Douglas Hays

Looks good to me. I don't see any performance differences on IE7. IE6 has a bunch of performance issues that we need to look but unrelated to this change.

comment:3 Changed 12 years ago by bill

Milestone: 0.91.0

OK, the patch above turned out not to work, weird stuff like losing checked status for an <input type="checkbox" checked>. Punting to 1.0. We think the current workaround is good enough. (The limitation is that the default value must be "" for all widgets except checkbox, where the default value must be "on")

comment:4 Changed 12 years ago by Douglas Hays

Milestone: 1.02.0

Deferring since the current workaround is still holding its own...

comment:5 Changed 12 years ago by bill

Resolution: wontfix
Status: newclosed

Let's just close this. The current "workaround" requires that the default value of "value" is "", but I'm willing to consider that as a known (and accepted) limitation of the dojo parser.

comment:6 Changed 11 years ago by alex

Milestone: 2.01.3

Milestone 2.0 deleted

Note: See TracTickets for help on using tickets.