| From | Sent On | Attachments |
|---|---|---|
| wu...@coyoten.at | Jan 23, 2007 11:52 pm | |
| wu...@coyoten.at | Jan 24, 2007 12:11 am | |
| vetalok | Dec 3, 2008 8:30 am |
| Subject: | Re: h:commandButton doesn't work with a4j:form ajaxSubmit=true | |
|---|---|---|
| From: | wu...@coyoten.at (wu...@coyoten.at) | |
| Date: | Jan 24, 2007 12:11:21 am | |
| List: | net.java.dev.ajax4jsf.issues | |
Hi,
sorry for posting my bug report directly into the mailing-list. I was blind. Sorry.
Best Regards
Stefan
On Wed, 24 Jan 2007 8:52:34 +0100, <wu...@coyoten.at> wrote:
Hi,
My problem is that a4j:form with ajaxSubmit="true" doesn't work for h:commandButton. The ajax request is send, but the action and actionListener method are never called. It seems that this is a general problem with a4j:form and ajaxSubmit="true" when using h:commandButton.
This is my Example Code:
<f:view> <a4j:form id="edit1" ajaxSubmit="true"> <h:commandButton value="ajax submit true" actionListener="#{tabButtonBean.callActionListener}" action="#{tabButtonBean.callAction}"></h:commandButton> </a4j:form> <h:form id="edit2"> <h:commandButton value="standard jsf without ajax" actionListener="#{tabButtonBean.callActionListener}" action="#{tabButtonBean.callAction}"></h:commandButton> </h:form> <h:form> <a4j:commandButton value="standard form with a4j:commandButton" actionListener="#{tabButtonBean.callActionListener}" action="#{tabButtonBean.callAction}"></a4j:commandButton> </h:form> <a4j:log popup="false" level="DEBUG"></a4j:log> </f:view>
public class TabButtonBean {
public void callActionListener(ActionEvent e) { System.out.println("Hello World " + e); }
public String callAction() { System.out.println("callAction()"); return null; } }
Best regards
Stefan





