Posts

Showing posts with the label JSP

Disabled Form Fields Strange Behavior

Disabled form fields of html will not get the values (or will get null) after submitting the Form:  Code like below for the input form fields in HTML will generate the disabled field. Disabled field is the one which is not editable, not focusable, won’t get tab navigation, and can’t select the field. These are the characteristics of the disabled form field. We can apply this attribute on all input fields, buttons, select box, etc.  Please find the code below: <input type=”text” name=”accountNumber” value=”123455” disabled=”disabled”   /> The above code will generate the disabled text field where we can’t be able to edit and select the field. Characteristics of Disabled form fields: 1)    Disabled form field cannot be focusable, i.e. you cannot focus the field. 2)    Disabled fields are non-editable. 3)    Disabled fields will not be submitted when submission of form happens or when we will click on ‘Submit’ button. 4)    Disabled fields will give n