José Manuel García Alonso schrieb:
> Hi
>  
> I'm trying to do something like that
>  
> <tr:iterator value="#{projects}" var="project">
>     <c:choose>
>         <c:when test="${project.foo()}">
>         </c:when>
>     </c:choose>
> </tr:iterator>
>  
> But I can't access to project var from JSTL tags. Somebody knows a way
> to access this var from JSTL tags?

You can't.

In JSF, *first* a component tree is built, *then* the component tree is
rendered. JSP/JSTL tags run during the "build" phase, but  tr:iterator
executes its contents during the "render" phase.

In general, you should avoid c:if and c:choose completely when writing
JSF applications. Use the JSF "rendered" attribute available on each
component instead.

See here for a general overview of JSF:
  http://wiki.apache.org/myfaces/JSF_and_MVC

Regards,
Simon

Reply via email to