-
1. Re: javascript call not work in a4j:include ??
sergeysmirnov Mar 17, 2007 12:10 PM (in response to edbras1)I have checked it and did not find any problem. The script is invoked even during the ajax rre-rendering. May be you have there a wrong path to a file. Add some text to the timer.xhtml to see that it is included itself for sure.
-
2. Re: javascript call not work in a4j:include ??
edbras1 Mar 18, 2007 3:04 AM (in response to edbras1)He Sergey,
Thanks for your time.
We solved it ;)..
The problem was that my javascript method was called but I use a method getElementById('bla') in the method. However, when the element bla is included in a a4j:include the bla id contains a prefix which is the id of the include element.
Why is this btw?.. and is this realy necessary?
Cheers,
Ed -
3. Re: javascript call not work in a4j:include ??
sergeysmirnov Mar 19, 2007 2:10 PM (in response to edbras1)Well, the a4j:include instead of ui:include might be used to navigate between the sub-views (for partial navigation feature) where the same id are possible. To avoid such conflict, a4j:include combines together f:view and jsp:include.
More formal reason is a #9.2.2 of the JSF Specification:- When using the <jsp:include> standard action (or the JSTL <c:import> action) to compose a single view from multiple JSP pages, all JSF component custom actions in included pages must be nested inside the <f:subview> custom action from the JSF Core Tag Library (which is itself nested inside the <f:view> custom action). The <f:subview> action itself may be present in the including page (i.e. with the <jsp:include> or <c:import> action nested inside it), or in the included page.