struts-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Tim Christopher <>
Subject Re: RequestURI (Action not JSP)
Date Mon, 28 Feb 2005 21:30:42 GMT

I'd like to be able to access the path of my Struts Action as the
Display Tag requires a parameter 'requestURI'.  It needs this
attribute so that it can append values to the end of the current url -
without the requestURI it will make the link point to the jsp which is
located under the WEB-INF directory.

The best way I can think of doing this is to extend the
RequestProcessor to add request.getRequestURI() as a variable stored
in each request.  I will then access like this within a JSP:

<% String a = (String) request.getAttribute("actionName"); %>
<display:table name="somecollection" requestURI="<%= a %>">
<display:column property="id" sortable="true"></display:column>

I don't seem to be able to extract it within the display:table tag
itself, no matter how I nest different "s and 's...  However as tables
are only on a relatively small number of pages I'm not sure this is
the best way, also it looks a bit clumsy,

Any suggestions?

Tim Christopher

To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message