Trying to avoid building my own menu for this, as it should be a very common
pattern to have a menu built from a list.  I am using richfaces which has
all of the AJAX stuff written for me.

On Mon, Aug 3, 2009 at 4:30 PM, John Carlson <[email protected]> wrote:

>  Ui:repeat can be used in faces markup (.jspx?)  There are cases when you
> need to use c:forEach instead of ui:repeat.
>
>
>
> Perhaps you should look for a dynamic menu that takes a collection.   Or
> build your menu in Java code (use or subclass a component in your code).
>
>
>
> John
>
>
>
> *From:* Scott Carter [mailto:[email protected]]
> *Sent:* Monday, August 03, 2009 2:11 PM
> *To:* MyFaces Discussion
> *Subject:* iterating over a list of items
>
>
>
> I know this subject is discussed in several places on the web, but I would
> like to get an updated expert opinion.  I need to iterate over a list of
> items defined in a backing bean.  In my case I am using the items in the
> list to construct a menu in richfaces so I will need to be able to iterate
> the list and define variables for each item to access the attributes.
>
>
>
> The 2 ways discussed from Google searches of achieving this are the
> facelets ui:repeat tag and the jstl c:foreach tag.  As I understand it the
> facelets ui:repeat tag can not be used in a jsp page, which is what I am
> using (jsp).  If I even try to include this tag, it is not found regardless
> if I have the facelets jar in my WEB-INF/lib directory.
>
>
>
> The c:foreach has several sites of documentation on what a bad idea it is
> to use jstl tags in JSF pages.
>
>
>
> So I am left asking the question, what is the best way to do this?  Any
> good code examples or links would be very appreciated as well as advice on a
> best practice here.
>
>
>
> Thanks in advance.
>

Reply via email to