Read this:
http://andrewfacelets.blogspot.com/2008/03/build-time-vs-render-time.html
On Tue, Jun 17, 2008 at 8:54 AM, Joris Kimpe <[EMAIL PROTECTED]> wrote:
>
> Hello group,
>
> I have a jsp (containing Trinidad components), and I want to include a
> second jsp page (using jsp:include). I'd like to pass a backing bean
> parameter to the included page (so I can use this value in a javascript
> function), but how can I do this?
>
> It appears to be impossible to use "#{row.shiftId}" inside the onclick
> attribute (which is in the included jsp). Or am I wrong? Also using
> ${param.shiftId} results in an error:
> According to TLD or attribute directive in tag file, attribute onclick does
> not accept any expressions
>
>
>
> These are my jsp files:
>
> first.jsp
> -------------------------------------------------------------------------------
> ...
> <f:subview id="overviewPage">
> <tr:table id="overviewTable" value="#{backingBean.dataModel}"
> var="row">
> ...
> <tr:panelFormLayout>
> <tr:table id="results" value="#{row.results}"
> var="result">
> <tr:column>
> <tr:outputLabel
> value="#{result.shift}"/>
> </tr:column>
> </tr:table>
>
>
> <jsp:include page="second.jsp">
> <jsp:param name="shiftId"
> value="#{row.shiftId}"/>
> </jsp:include>
> </tr:panelFormLayout>
> ...
> </tr:table>
> </f:subview>
>
>
>
>
> second.jsp
> -------------------------------------------------------------------------------
> <f:subview id="createAbsence">
> <tr:panelPopup onclick="jsFunction('${param.shiftId}');" text="create"
> modal="true" position="relative">
> <tr:selectOneChoice label="type" value="#{backingBean.type}"
> required="yes" immediate="true">
> <f:selectItems
> value="#{personalShiftPlanOverviewActions.absenceTypes}"
> />
> </tr:selectOneChoice>
> ...
> </tr:panelPopup>
> </f:subview>
>
>
> Thanks for your help!
>
> Joris
> --
> View this message in context:
> http://www.nabble.com/-TRINIDAD--include-jsp-using-param-tp17912565p17912565.html
> Sent from the MyFaces - Users mailing list archive at Nabble.com.
>
>