Modified disabled attribute of input tag to support values "disabled" and "true"
This commit is contained in:
parent
019545ccd9
commit
3dadfff50b
1 changed files with 3 additions and 2 deletions
|
@ -215,9 +215,10 @@ public class InputElementFormattingTag extends TagSupport {
|
||||||
}
|
}
|
||||||
|
|
||||||
private String doDisabled() {
|
private String doDisabled() {
|
||||||
/* only insert the disabled attribute if it has been populated */
|
/* Only insert the disabled attribute if it has been populated. Support
|
||||||
|
* both "true" and "disabled" as values. */
|
||||||
String disabled = getDisabled();
|
String disabled = getDisabled();
|
||||||
if (!StringUtils.isEmpty(disabled)) {
|
if ("true".equals(disabled) || "disabled".equals(disabled)) {
|
||||||
return "disabled=\"disabled\"";
|
return "disabled=\"disabled\"";
|
||||||
}
|
}
|
||||||
return "";
|
return "";
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue