You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@wicket.apache.org by eugenebalt <eu...@yahoo.com> on 2011/08/22 18:31:22 UTC
How to update the value of a Hidden Field using Ajax
How to update the value of a hidden filed using ajax?
I was trying to do something like the following
listYears.add(new AjaxFormComponentUpdatingBehavior("onchange") {
protected void onUpdate(AjaxRequestTarget target)
{
HiddenField field = (HiddenField) get("hiddenDateCheck" );
field.setConvertedInput("blahblah blan");
target.addComponent(hiddenField2);
}
});
Two problems….one is the value is never changed when I view the source of
the html and two, I can no longer use document.getElementById in my
javascript because I had to set the outputMarkupId = true for the hidden
field which overrides the setattribute modifier on “ID”
--
View this message in context: http://apache-wicket.1842946.n4.nabble.com/How-to-update-the-value-of-a-Hidden-Field-using-Ajax-tp3760600p3760600.html
Sent from the Users forum mailing list archive at Nabble.com.
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
For additional commands, e-mail: users-help@wicket.apache.org