Ajax4JSF not Rendering at all
schinni Feb 12, 2008 2:08 AMHi,
My environment is Netbeans 6 visual web JSF app with RichFaces 3.1.3. I am unable to get any component to rerender upon completion of an ajax request. Is there something wrong in the logic i am following or is it a configuration issue or is it a bug? I will be grateful for any help in this regard. Thank you.
A snippet of the code i am using:
JSP:
<jsp:root version="2.1" xmlns:a4j="http://richfaces.org/a4j" xmlns:f="http://java.sun.com/jsf/core" xmlns:h="http://java.sun.com/jsf/html"
xmlns:jsp="http://java.sun.com/JSP/Page" xmlns:rich="http://richfaces.org/rich" xmlns:webuijsf="http://www.sun.com/webui/webuijsf">
<jsp:directive.page contentType="text/html;charset=UTF-8" pageEncoding="UTF-8"/>
<f:view>
<webuijsf:page binding="#{AboutUs.page1}" id="page1">
<webuijsf:html binding="#{AboutUs.html1}" id="html1">
<webuijsf:head binding="#{AboutUs.head1}" id="head1">
<webuijsf:link binding="#{AboutUs.link1}" id="link1" url="/resources/stylesheet.css"/>
</webuijsf:head>
<webuijsf:body binding="#{AboutUs.body1}" id="body1" style="-rave-layout: grid">
<webuijsf:form binding="#{AboutUs.form1}" id="form1">
<webuijsf:image binding="#{AboutUs.image1}" height="2" id="image1"
style="background-repeat: repeat-x; left: 6px; top: 493px; position: absolute" url="/resources/pic/blue_lt_gradient.gif" width="948"/>
<webuijsf:textField binding="#{AboutUs.textField1}" id="textField1"
style="position: absolute; left: 174px; top: 72px; width: 228px; height: 18px" valueChangeListenerExpression="#{AboutUs.textField1_processValueChange}">
<a4j:support action="#{AboutUs.textField1_action}" event="onChange" reRender="textField1"/>
</webuijsf:textField>
<webuijsf:textField binding="#{AboutUs.textField2}" id="textField2" style="position: absolute;left: 174px; top: 132px; width: 132px; height: 24px">
<a4j:support action="#{AboutUs.textField1_action}" event="onChange" reRender="textField1"/>
</webuijsf:textField>
</webuijsf:form>
</webuijsf:body>
</webuijsf:html>
</webuijsf:page>
</f:view>
</jsp:root>
The Backing Bean function:
public String textField1_action() {
this.getTextField1().setText("Hello World!");
return null;
}