You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@myfaces.apache.org by Jurgen Lust <Ju...@UGent.be> on 2006/01/24 16:17:45 UTC

myfaces + tiles + ajaxanywhere

Hi, 
 
I've been trying to get ajaxanywhere (version 1.1.0.6) to work in my 
project, which is a MyFaces 1.1.1 webapp with Tiles using the 
JspTilesViewHandlerImpl. 
I tried the dependent_select example and it doesn't work: upon selecting 
an item in the first select box, the ajax request is sent to the server, 
and in the backing bean everything happens the way it should. However 
the zone on my page does not get updated (it does in the demo war). 
In my tomcat log file I get the 2 lines 'state = null' and 'tree = 
null', whereas in the demo war example, the value of each is a 
base64-encoded string. 
 
What could I be doing wrong?

Here's my JSP (only the body of the page, using Tiles):

<%@ taglib uri="http://java.sun.com/jsf/core" prefix="f"%>
<%@ taglib uri="http://java.sun.com/jsf/html" prefix="h"%>
<%@ taglib uri="http://myfaces.apache.org/tomahawk" prefix="t"%>
<%@ taglib uri="http://ajaxanywhere.sourceforge.net/" prefix="aa"%>

<t:htmlTag value="h1">
    <h:outputText value="#{bundle.ApplicationName}" />
</t:htmlTag>

<h:form id="postingStep1JSFForm">
    <h:panelGrid columns="1">
        <h:panelGroup>
            <h:selectOneListbox size="10"
                value="#{ajaxExampleHandler.category1}"
                
valueChangeListener="#{ajaxExampleHandler.onSelectCategoryValueChange1}"
                id="category1" onchange="ajaxAnywhere.submitAJAX();"
                required="true">
                <f:selectItems value="#{ajaxExampleHandler.items1}"
                    id="items1" />
            </h:selectOneListbox>

            <aa:zoneJSF id="categoryList">
                <h:selectOneListbox size="10"
                    value="#{ajaxExampleHandler.category2}"
                    id="category2" required="true">
                   
                    <f:selectItems value="#{ajaxExampleHandler.items2}"
                        id="items2" />
                </h:selectOneListbox>
            </aa:zoneJSF>

        </h:panelGroup>

        <h:inputHidden value="" />
    </h:panelGrid>
</h:form>

Kind regards,

Jurgen

-- 
Among flowers, the cherry blossom.
Among men, me.