On 7/9/2014 11:11 PM, Martin Grigorov wrote:
There are three types of HTML buttons: submit, reset and button. You need
the third one: <button type="button">Like Link</button>.

Ah, yes---I was a little HTML-rusty and the "button" type slipped my mind.

Unfortunately, using type="button" my Button.onClick() method still does not get called. Only when I change it to type="submit" does my Button.onClick() method get called.

For now I'm going to turn off the "required" attributes and let Wicket do all the validation on the server side, which in this case is probably better, anyway. But I still think it is a Wicket shortcoming that does not allow a Button to receive input from a <button> unless the <button> is set to submit so that the browser thinks the form will be submitted, even if Wicket decided to skip form processing on the server side. A Button click should be able to be detected regardless of whether it submits the form or not in the HTML, in my opinion.

Cheers,

Garret

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org

Reply via email to