Closed Bug 149962 Opened 22 years ago Closed 22 years ago

Browser doesn't remember values in hidden form elements

Categories

(Core :: DOM: Forms, defect, P3)

x86
Windows 2000
defect

Tracking

()

VERIFIED FIXED
mozilla1.2beta

People

(Reporter: rjonasson, Assigned: john)

References

()

Details

(Whiteboard: [FIX])

Attachments

(1 file, 1 obsolete file)

From Bugzilla Helper: User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.0; en-US; rv:1.0.0) Gecko/20020530 BuildID: 2002053012 I have a form submission page on an intranet that contains text elements. I use Javascript to fill in hidden elements based on what was entered in the text elements. When I hit "Submit", the hidden elements get passed to the web server properly. If I hit "Back", the value of the hidden element gets lost. Reproducible: Always Steps to Reproduce: 1.load http://www.jonasson.org/mozform.html 2.enter something in the box and click submit. You should see that MyText and MyOtherText have the same value 3.hit back and immediately hit submit again 4. you should see that MyText got passed properly, but MyOtherText now has no value. Actual Results: MyOtherText has no value Expected Results: MyOtherText would have the same value it had when the form was submitted. The browser should remember it's value. Was able to reproduce on ASP and PHP environments, so it does appear to be a mozilla bug.
confirmed. there is a difference in the way MOZ and IE restore the values for the hidden elements. was this always so?
Status: UNCONFIRMED → NEW
Ever confirmed: true
Priority: -- → P3
Target Milestone: --- → mozilla1.2beta
It should be done. I have a patch percolating.
Assignee: alexsavulov → jkeiser
Status: NEW → ASSIGNED
Attached patch Patch (obsolete) (deleted) — Splinter Review
This should fix it. Had to add stuff in save as well as restore.
Attached patch Patch (deleted) — Splinter Review
This should fix it. Had to add stuff in save as well as restore.
Attachment #87191 - Attachment is obsolete: true
Looks like Bugzilla's a little funny just after the upgrade. The patch also consolidates some redundant stuff from an if() in nsHTMLInputElement::SetValueSecure().
Whiteboard: [FIX]
Comment on attachment 87192 [details] [diff] [review] Patch r=rods
Attachment #87192 - Flags: review+
Attachment #87192 - Flags: superreview+
Fix checked in to trunk.
Status: ASSIGNED → RESOLVED
Closed: 22 years ago
Resolution: --- → FIXED
Verifying on build 2002-06-12-08-trunk on windows 98 and Linux
Status: RESOLVED → VERIFIED
Component: HTML: Form Submission → DOM: Core & HTML
Component: DOM: Core & HTML → DOM: Forms
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: