I'm mistified why a checkbox would show up disabled.
What do I need to do to enable it? Already tried using String object for the requestInvoice property, does not help.
JSP:
<fieldset class="aa-list-primary-indent">
<label class="custombox-wrapper custombox" data-behavior="custombox">
<div class="control checkbox"></div>
<html-el:checkbox styleId="requestInvoiceCheckbox" property="form(creditCardForm).personalId.requestInvoice" />
In need of an invoice (factura)
</label>
</fieldset>
Form:
private boolean requestInvoice = false;
public boolean isRequestInvoice() {
return requestInvoice;
}
public void setRequestInvoice(boolean requestInvoice) {
this.requestInvoice = requestInvoice;
}
HTML generated by the browser (Chrome):
<input type="checkbox" name="form(creditCardForm).personalId.requestInvoice" value="on" id="requestInvoiceCheckbox">
Sorry, it's a bad question. The CSS setup makes the checkbox look disabled, even though it is not. Bad CSS design. All the JSP/Java/HTML code above is fine.
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.