myfaces-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Mario Ivankovits <>
Subject Re: [announcement] new sandbox component: submitOnEvent
Date Wed, 11 Oct 2006 06:19:57 GMT
Hi Jeff!
> I notice you didn't need to forceID the submit buttons on the example.
> Do we run into any ID trouble with subviews, forms, subforms, etc?
Shouldn't be a problem. I use the JSF computed client-id, and if there
isn't a bug in this computation (there were in the past ;-) ) it should
> <h:outputLabel for="text2" value="submit via link on enter"/>
> <h:inputText id="text2" value="#{submitOnEvent.strings.text2}"
> onkeypress="javascript:notifyOriginalEvent()">
>      <s:submitOnEvent for="submitLink" />
> </h:inputText>
> How does it know that onEnter() is the event to submit on?
Well, my first idea was to create a "submitOnEnter" component, then, we
decided to allow a broader use-case and allow to configure the event,
following the "convention-before-configuration" paradigm all default
values of the submitOnEvent are so that it will trigger "onkeypress" and
the "enter" key.

Yea, I admit it is somehow confusing, but once you know this it is a
real time saver ;-)


View raw message