This content has been marked as final.
Show 2 replies
-
1. Re: using a4j:support with JS event handlers
ilya_shaikovsky Sep 13, 2007 1:10 PM (in response to maumas)You may use onsubmit and oncomplete attributes of support to invoke the JS code after and before submit.
-
2. Re: using a4j:support with JS event handlers
maksimkaszynski Sep 13, 2007 2:11 PM (in response to maumas)1) You need to modify your code by transfering onchange JS code to a4j:support onsubmit attribute. e.g.
<h:inputText id="txt1" value="#{sampleBean.person.name}"> <a4j:support event="onchange" onsubmit="validate_txt1();" ajaxSingle="true" rerender="output"/> </h:inputText>
2)In JavaScript, you can add multiple listeners to the same component. For reference, see http://www.quirksmode.org/dom/w3c_events.html#registration