The following comment has been added to this issue: Author: Mass Dosage Created: Wed, 20 Oct 2004 11:53 AM Body: OK, I tried the alternating sort code that you specified, and then the header comes out like so:
<thead> <tr> <th class="sortable"> <a href="?d-4001840-s=0&d-4001840-o=2">First Name</a></th> <th>Last Name</th> <th class="sortable"> <a href="?d-4001840-s=2&d-4001840-o=2">First Name</a></th> <th>Last Name</th> <th class="sortable"> <a href="?d-4001840-s=4&d-4001840-o=2">First Name</a></th> <th>Last Name</th> <th class="sortable"> <a href="?d-4001840-s=6&d-4001840-o=2"></a></th></tr></thead> i.e. alternating First Name and Last Name and no other headers. Then I thought I would give this a go (i.e. no sorting at all): <display:table name="${employees}" id="employee" pagesize="40" requestURI=""> <display:column property="firstName" titleKey="employee.firstname"/> <display:column property="lastName" titleKey="employee.lastname" /> <display:column property="mobileNumber" titleKey="employee.mobile"/> <display:column property="landlineNumber" titleKey="employee.landline"/> <display:column property="faxNumber" titleKey="employee.fax"/> <display:column property="emailAddress" titleKey="employee.email"/> <display:column title=""><a href="employee_edit.do?id=${employee.id}"><fmt:message key="employee.list.edit"/></a></display:column> </display:table> This generates the following header: <thead> <tr> <th>First Name</th> <th>First Name</th> <th>First Name</th> <th>First Name</th> <th>First Name</th> <th>First Name</th> <th></th></tr></thead> Nothing but first name! --------------------------------------------------------------------- View this comment: http://jira.codehaus.org/browse/DISPL-72?page=comments#action_25622 --------------------------------------------------------------------- View the issue: http://jira.codehaus.org/browse/DISPL-72 Here is an overview of the issue: --------------------------------------------------------------------- Key: DISPL-72 Summary: titleKey reads incorrect values from properties Type: Bug Status: Unassigned Priority: Major Original Estimate: Unknown Time Spent: Unknown Remaining: Unknown Project: DisplayTag Components: I18N Versions: 1.0 RC2 Assignee: Reporter: Mass Dosage Created: Wed, 20 Oct 2004 7:00 AM Updated: Wed, 20 Oct 2004 11:53 AM Description: Using the latest dev snapshot from today I have been trying to use the new titleKey column attribute to do i18n. I have JSP like so: <display:table name="${employees}" id="employee" pagesize="40" requestURI=""> <display:column property="firstName" titleKey="employee.firstname" sort="true"/> <display:column property="lastName" titleKey="employee.lastname" sort="true"/> <display:column property="mobileNumber" titleKey="employee.mobile"/> <display:column property="landlineNumber" titleKey="employee.landline"/> <display:column property="faxNumber" titleKey="employee.fax"/> <display:column property="emailAddress" titleKey="employee.email"/> <display:column title=""><a href="employee_edit.do?id=${employee.id}"><fmt:message key="employee.list.edit"/></a></display:column> </display:table> This iterates through all employees in the list and outputs their properties. The table headers should all have values looked up from the properties specified by the "titleKey" attributes. Fine. I have a "messages.properties" file on my classpath and spring is configured to pick this up, it gets them correctly if I use "fmt:message" tags, so I know the reading in of the properties is working. The messages are like so: employee.firstname=First Name employee.mobile=Mobile Number employee.lastname=Last Name employee.landline=Landline Number employee.fax=Fax employee.email=E-mail so they match the values used for "titleKey". All good so far. However, when I open the JSP page in the browser I get very strange results for the table headers: <thead><tr> <th class="sortable"> <a href="?d-4001840-s=0&d-4001840-o=2">First Name</a></th> <th class="sortable"> <a href="?d-4001840-s=1&d-4001840-o=2">First Name</a></th> <th>Mobile Number</th> <th>Mobile Number</th> <th>Mobile Number</th> <th>Mobile Number</th> <th></th></tr></thead> It gets the first name correct, then incorrectly replaces last name with first name, then gets mobile number correct, then incorrectly replaces all others with mobile number. Any ideas? Have I configured something wrong? I don't think so 'cos some of the properties are being read in correctly, but not all. --------------------------------------------------------------------- JIRA INFORMATION: This message is automatically generated by JIRA. If you think it was sent incorrectly contact one of the administrators: http://jira.codehaus.org/secure/Administrators.jspa If you want more information on JIRA, or have a bug to report see: http://www.atlassian.com/software/jira ------------------------------------------------------- This SF.net email is sponsored by: IT Product Guide on ITManagersJournal Use IT products in your business? Tell us what you think of them. Give us Your Opinions, Get Free ThinkGeek Gift Certificates! Click to find out more http://productguide.itmanagersjournal.com/guidepromo.tmpl _______________________________________________ displaytag-devel mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/displaytag-devel