RE: Sorting table columns in jsp using struts

2004-03-05 Thread as as
Henri, Thanks for the explanatory smaples.The syntax below seems JSTL c:forEach var=category items=${requestScope.categories} tr tda Any quick intro I read on JSTL... Thanks Henri Yandell [EMAIL PROTECTED] wrote: Just to show how easy it can be with beanutils:

RE: Sorting table columns in jsp using struts

2004-03-05 Thread A.White
I'm reading a really good book at the moment, JSTL : Practical Guide for JSP Programmers -Original Message- From: as as [mailto:[EMAIL PROTECTED] Sent: 05 March 2004 13:48 To: Struts Users Mailing List Subject: RE: Sorting table columns in jsp using struts Henri, Thanks

RE: Sorting table columns in jsp using struts

2004-03-05 Thread as as
Thank you! A.White [EMAIL PROTECTED] wrote:I'm reading a really good book at the moment, JSTL : Practical Guide for JSP Programmers -Original Message- From: as as [mailto:[EMAIL PROTECTED] Sent: 05 March 2004 13:48 To: Struts Users Mailing List Subject: RE: Sorting table columns in jsp

RE: Sorting table columns in jsp using struts

2004-03-05 Thread Robert Taylor
The JSTL spec is a great reference. I would recommend you download it. robert -Original Message- From: as as [mailto:[EMAIL PROTECTED] Sent: Friday, March 05, 2004 8:48 AM To: Struts Users Mailing List Subject: RE: Sorting table columns in jsp using struts Henri, Thanks

RE: Sorting table columns in jsp using struts

2004-03-05 Thread Henri Yandell
reading a really good book at the moment, JSTL : Practical Guide for JSP Programmers -Original Message- From: as as [mailto:[EMAIL PROTECTED] Sent: 05 March 2004 13:48 To: Struts Users Mailing List Subject: RE: Sorting table columns in jsp using struts Henri, Thanks

RE: Sorting table columns in jsp using struts

2004-03-05 Thread as as
: Thank you! A.White wrote:I'm reading a really good book at the moment, JSTL : Practical Guide for JSP Programmers -Original Message- From: as as [mailto:[EMAIL PROTECTED] Sent: 05 March 2004 13:48 To: Struts Users Mailing List Subject: RE: Sorting table columns in jsp using struts

RE: Sorting table columns in jsp using struts

2004-03-04 Thread Wendy Smoak
Sam wrote: Any clues on best easy ways to do table column sorting my rows in the table are generated as follows using logic:iterate as below. I do it on the server side, holding the items to be sorted in a Map and creating a new Map passing a Comparator to the constructor to get the new

RE: Sorting table columns in jsp using struts

2004-03-04 Thread as as
Wendy, Thanks for the quick reply. books is a session attribute (request.setParameter(books,books) I retrieve books from database - Book.java so books is a List object. Will try your approach and post back the results Thanks, Sam~~ Wendy Smoak [EMAIL PROTECTED] wrote: Sam wrote: Any clues on

RE: Sorting table columns in jsp using struts

2004-03-04 Thread Henri Yandell
BeanUtils' BeanComparator is a useful way to do the sorting by the way, and will be in your classpath if you're using Struts [depending on version]. Also ReverseComparator in Commons Collections. Between them you can write a nice abstract table sorting system. Hen On Thu, 4 Mar 2004, as as

RE: Sorting table columns in jsp using struts

2004-03-04 Thread as as
thanks much. sample code by any cance? Thank you! ~~Sam Henri Yandell [EMAIL PROTECTED] wrote: BeanUtils' BeanComparator is a useful way to do the sorting by the way, and will be in your classpath if you're using Struts [depending on version]. Also ReverseComparator in Commons Collections.

RE: Sorting table columns in jsp using struts

2004-03-04 Thread Henri Yandell
I imagine display tags does it for you mostly if you go that way, else I'll knock up an example tonight. Finally getting back into taglibs and jsp :) Hen On Thu, 4 Mar 2004, as as wrote: thanks much. sample code by any cance? Thank you! ~~Sam Henri Yandell [EMAIL PROTECTED] wrote:

RE: Sorting table columns in jsp using struts

2004-03-04 Thread as as
Thanks in advance. Sam (I am currently truying out display tag though, as per Ashish) Henri Yandell [EMAIL PROTECTED] wrote: I imagine display tags does it for you mostly if you go that way, else I'll knock up an example tonight. Finally getting back into taglibs and jsp :) Hen On Thu, 4 Mar

RE: Sorting table columns in jsp using struts

2004-03-04 Thread Faus, Lee
Check out displaytag. http://displaytag.sourceforge.net/tagreference.html. There is a sort. Look through the examples. I have done this for many customers. -Original Message- From: as as [mailto:[EMAIL PROTECTED] Sent: Thursday, March 04, 2004 13:13 To: [EMAIL PROTECTED] Subject:

RE: Sorting table columns in jsp using struts

2004-03-04 Thread Henri Yandell
Just to show how easy it can be with beanutils: display_categories.do points to a struts action that preloads like: * List list = new ArrayList(); list.addAll( DummyDao.getAllCategories() ); String sortBy = request.getParameter(sortBy); if(sortBy != null) {