This content has been marked as final.
Show 7 replies
-
1. Re: Passing parameters in a4j:include
bibinsga25 Feb 27, 2008 9:55 AM (in response to bibinsga25)Also when I tried this through updating the request parameter map instead of appending the value in the url,Im getting the following error
Caused by: javax.el.ELException: /pages/customer-edit.jspx @16,104 viewId="#{customerTree.currentDynamicView}": Error reading 'currentDynamicView' -
2. Re: Passing parameters in a4j:include
bibinsga25 Feb 27, 2008 10:11 AM (in response to bibinsga25)Is there any way of combining a4j:include and a4j:actionParam??
-
3. Re: Passing parameters in a4j:include
bibinsga25 Feb 27, 2008 10:58 AM (in response to bibinsga25)somebody please respond.Im stuck up with this issue.Please................
-
4. Re: Passing parameters in a4j:include
ilya_shaikovsky Feb 28, 2008 7:25 AM (in response to bibinsga25)<a4j:include viewId="/pages/included1.xhtml"> <ui:param name="param" value="page1"/> </a4j:include>
included page<ui:composition> <h:form> <h:outputText value="#{param}"></h:outputText> </h:form> </ui:composition>
after opening page - i'm able to see my param in output. -
5. Re: Passing parameters in a4j:include
bibinsga25 Feb 28, 2008 9:03 AM (in response to bibinsga25)Thanks for the reply...
but I am not able to get it from the bean
I tried like
getHttpRequest().getParameter("param") and its returning null.
Actually I want to process something with the id which I am passing with include from the backing beans.Please.... -
6. Re: Passing parameters in a4j:include
ilya_shaikovsky Feb 28, 2008 11:24 AM (in response to bibinsga25)ok, sorry.. more detailed code:
main:<ui:composition template="/templates/common.xhtml"> <ui:define name="body"> <a4j:outputPanel id="view" > <a4j:include viewId="/pages/included1.xhtml"> <ui:param name="currentPage" value="page1"/> </a4j:include> </a4j:outputPanel> </ui:define> </ui:composition>
include:<ui:composition> <h:form> <h:commandLink value="submit with current param" action="#{bean.action}"> <f:param name="currentPage" value="#{currentPage}"/> </h:commandLink> </h:form> </ui:composition>
there you can see that parameter passed to the child page.
and bean code:public String action() { System.out.println(FacesContext.getCurrentInstance().getExternalContext().getRequestParameterMap().get("currentPage")); return null; }
there the parameter (passed with f:param) get and printed to console.
In my log for this code I have:INFO: BEFORE INVOKE_APPLICATION 5 action called page1 28.02.2008 18:18:34 org.exadel.jsf.PhaseTracker afterPhase INFO: AFTER INVOKE_APPLICATION 5
-
7. Re: Passing parameters in a4j:include
bibinsga25 Feb 29, 2008 12:12 AM (in response to bibinsga25)Thanks very much for the reply :-)