如何从 javascript 更改支持 bean web 元素的值?
xhtml:
<h:form >
<input type="hidden" id="elementid" name="element" value="#{BackingBean.elementid}" />
豆子:
public class BackingBean implements Serializable {
protected String elementid = "";
javascript:
document.getElementById('elementid').value = 'new value';