#7482 closed bug (patchwelcome)
.html() does not work when <input type="text"> is updated
Reported by: | Owned by: | ||
---|---|---|---|
Priority: | low | Milestone: | 1.5 |
Component: | attributes | Version: | 1.4.4 |
Keywords: | Cc: | ||
Blocked by: | Blocking: |
Description
This should explain it all. Look at the alert, it's not displaying what is expected.
Change History (3)
comment:1 Changed 12 years ago by
Component: | unfiled → attributes |
---|---|
Keywords: | needsreview added |
Priority: | undecided → low |
Status: | new → open |
comment:2 Changed 12 years ago by
Resolution: | → patchwelcome |
---|---|
Status: | open → closed |
comment:3 Changed 12 years ago by
Keywords: | needsreview removed |
---|
Note: See
TracTickets for help on using
tickets.
When you set the value of an input element using .val() (or elem.value), you are updating a DOM property, not an HTML attribute. This issue comes up frequently. As to just why .val() is so anomalous, I cannot provide a great answer at the moment. I am not sure if this is something that is "fixable" with jQuery or if it is an issue inherent to this particular property. Perhaps someone else can provide some illumination?