Why is the attribute size of h:selectManyListbox redefined in Google chrome?
I have some problem using JSF <h:selectManyListbox>
and Google Chrome.
When my page is loading an error "Attribute size redefined" appears. I just want to see only 5 items in my list box:
<h:selectManyListbox id="usersManyListbox" value="#{pingResultBean.selectedUsers}"
size="5" style="width:168p开发者_Go百科x;">
<f:selectItems value="#{pingResultBean.userItems}"/>
</h:selectManyListbox>
In other browsers everything is OK.
This error means that the mentioned attribute appeared twice in the generated HTML source. Rightclick the page in your browser and locate the HTML generated by <h:selectManyListbox>
. It should look like
<select name="formId:usersManyListbox" multiple="multiple" size="5">
It should have only one size
attribute. If it do have two or more, then it's likely a bug in the JSF impl/version used. Consider upgrading to the latest version or switching to a different impl.
I can at least not reproduce this on Mojarra 1.2_15 and Mojarra 2.1.0.
精彩评论