I'm using displayTag in a project. Everything was going well, until I came across a problem with titleKey. I resolved this by upgrading to the latest release and using (in the displaytag.properties file):
Everything appears OK, but the links in the display column have changed from using "&" in 1.0-rc1 to "%26" in 1.0. (Also the "=" becomes "%3D"). However, when I switch back to 1.0-c1 the titleKey now fails.
Does anyone know how to resolve this?
Many thanks.
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
I would recommend using the i18nJstlAdapter, which is the default and doesn't require configuration. Do do this, just put the following in your web.xml:
<!-- Define the basename for a resource bundle for I18N --><context-param><param-name>javax.servlet.jsp.jstl.fmt.localizationContext</param-name><param-value>ApplicationResources</param-value></context-param>
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Thanks Matt,
I've put your suggestion into the web.xml, and removed the configuration from the displaytag.properties file. The titleKey is working fine, but the problem with the URL's in the "paramProperty" attribute of the <display:column> tag remain. (In version 1.0 anyway).
If I hard-code the link outside of the tag it works, but if it's generated by the display:column tag it removes the "&" character and puts in "%26" instead.
I'm using displayTag in a project. Everything was going well, until I came across a problem with titleKey. I resolved this by upgrading to the latest release and using (in the displaytag.properties file):
locale.resolver=org.displaytag.localization.I18nStrutsAdapter
locale.provider=org.displaytag.localization.I18nStrutsAdapter
Everything appears OK, but the links in the display column have changed from using "&" in 1.0-rc1 to "%26" in 1.0. (Also the "=" becomes "%3D"). However, when I switch back to 1.0-c1 the titleKey now fails.
Does anyone know how to resolve this?
Many thanks.
OK, I've given up trying to change the %26 to & and change the %3D to a =.
Just in case anyone has similar problems, I'm no doing it this way:
<c:set var='count' scope='page' value='${0}'/>
<display:table class='list' requestURI='useSearch.do' requestURIcontext='false' id='parent' name='usersSearchForm.usersList' export='true' sort='list' pagesize='10'>
<display:column width='5' titleKey='entity.edit' href='useEdit.do'>
<a href='useEdit.do?stub=&useUsername=<c:out value='${usersSearchForm.usersList[count].useUsername}'/>'><bean:message key='entity.edit'/></a>
</display:column>
<c:set var='count' value='${count + 1}'/>
</display:table>
I'm now having problems with exporting, but I'll put this into a separate thread.
James.
I would recommend using the i18nJstlAdapter, which is the default and doesn't require configuration. Do do this, just put the following in your web.xml:
Thanks Matt,
I've put your suggestion into the web.xml, and removed the configuration from the displaytag.properties file. The titleKey is working fine, but the problem with the URL's in the "paramProperty" attribute of the <display:column> tag remain. (In version 1.0 anyway).
If I hard-code the link outside of the tag it works, but if it's generated by the display:column tag it removes the "&" character and puts in "%26" instead.
Here's my code:
<display:column titleKey="usersForm.useFirstname.displayName" property="useFirstname" group="1" sortable="true" href="../useEdit.do" paramId="stub" paramProperty="primaryKeyParameters" />
Any idea's?
Thanks.