webtier@glassfish.java.net

Re: [webtier] JSF&Facelets: Outputting Components to the view

From: Ryan Lubke <Ryan.Lubke_at_Sun.COM>
Date: Tue, 24 Feb 2009 21:15:10 -0800

On 2/24/09 8:41 PM, Lincoln Baxter, III wrote:
> Hi All,
>
> I've got a bean that is building a list of components, and I want to
> add them to the display tree using a <ui:repeat>, but I'm having some
> trouble. I can't get them to render.
>
> <ui:repeat var="n" value="#{homeBean.notifications}">
> <li><h:outputText binding="#{n}" /></li>
> </ui:repeat>
>
> The components are simple HtmlOutputText components built dynamically
> in Java. What is the best way to get these to be included as part of
> the View?
>
I would recommend using c:forEach.
> Thanks,
> Lincoln