1
<display:column title="Edit Here">
   <s:url id="url1" action="editAction">
   <s:param name="id">
      <s:property value="news.id" />
   </s:param>
   </s:url>
   <s:a href="%{url1}">Edit</s:a>
</display:column>

id is property in my action class,zero is being passed everytime rather than the corresponding id of the table.

Andrea Ligios
  • 49,480
  • 26
  • 114
  • 243
lucky
  • 33
  • 1
  • 5

1 Answers1

0

Change this

<s:param name="id">
    <s:property value="news.id" />
</s:param>

to this:

<s:param name="id" value="#attr.news.id"></s:param>

It should be enough.

#attr is the OGNL used to access the pageContext (then request, session and application scopes).

Andrea Ligios
  • 49,480
  • 26
  • 114
  • 243