If you think a bug might affect users in the 57 release, please set the correct tracking and status flags for Release Management.

Pressing the ESCAPE key twice on a 'readonly' form element renders it blank.

RESOLVED WORKSFORME

Status

()

Firefox
General
RESOLVED WORKSFORME
13 years ago
12 years ago

People

(Reporter: Roel Linssen, Assigned: Blake Ross)

Tracking

({html4})

Trunk
x86
Windows XP
html4
Points:
---

Firefox Tracking Flags

(Not tracked)

Details

(URL)

(Reporter)

Description

13 years ago
User-Agent:       Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.1; .NET CLR 1.1.4322)
Build Identifier: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.7) Gecko/20040707 Firefox/0.9.2

Pressing the ESCAPE key twice when a 'readonly' form element has focus renders 
it blank (see i.e. 
http://www.htmlcodetutorial.com/forms/_INPUT_DISABLED.html). This behaviour 
doesn't happen in Internet Explorer 6 and is not according to the W3C 
specifications (http://www.w3.org/TR/REC-html40/interact/forms.html#adef-
readonly). Javascript confirms the value of the form element is now "".

Additionally, in my own document, using:
<input onmouseover="alert(this.value)" readonly type="text" value="Algemeen">
yields the following error when "mouseover" event is triggered:

Error: [Exception... "'Permission denied to get property 
XULElement.selectedIndex' when calling method: 
[nsIAutoCompletePopup::selectedIndex]"  nsresult: "0x8057001e 
(NS_ERROR_XPC_JS_THREW_STRING)"  location: "JS frame :: <unknown filename> :: 
onmouseover :: line 0"  data: no]

Reproducible: Always
Steps to Reproduce:
1. Click on any readonly (INPUT) form element
2. It receives focus (it should) but is not editable
3. Press the 'escape' button twice
4. The form element is now blank

Actual Results:  
N.A.

Expected Results:  
Should have left the value of the form element intact!

Comment 1

13 years ago
WFM, Mozilla 1.7 and trunk 2004-08-07-06 Linux
Assignee: nobody → firefox
Component: Layout: Form Controls → General
Product: Browser → Firefox
QA Contact: core.layout.form-controls → firefox.general

Comment 2

13 years ago
I can confirm on:

Mozilla/5.0 (Windows; U; Win98; en-US; rv:1.7.2) Gecko/20040810 Firefox/0.9.1+

But the problem does not exist in:

Mozilla/5.0 (Windows; U; Win98; en-US; rv:1.7) Gecko/20040616
Status: UNCONFIRMED → NEW
Ever confirmed: true

Comment 3

12 years ago
WFM Mozilla/5.0 (Macintosh; U; PPC Mac OS X Mach-O; en-US; rv:1.8b4)
Gecko/20050817 Firefox/1.0+
Status: NEW → RESOLVED
Last Resolved: 12 years ago
Keywords: html4
Resolution: --- → WORKSFORME

Comment 4

12 years ago
Still happens with text fields that aren't read-only: bug 305272.
You need to log in before you can comment on or make changes to this bug.