You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@struts.apache.org by fea jabi <zy...@hotmail.com> on 2006/03/29 22:08:02 UTC

href in a table column

This is struts related question itself. using displaytag too.

I created an obj whose attributes represent the row obj of a display table.

RowObj
type
navigate
total

<display:table name="${data}" id="rows" requestURI="PrepareEntry.do">
      <!--  Type -->
      <display:column titleKey="lbl.type">
             <a href="${rows.navigate}.do"> ${rows.Type} </a>
      </display:column>

       <!-- Total -->
       <display:column property="total" titleKey="lbl.total"/>
</display:table>

clicking on each element in first column should navigate to different JSP.
i.e
clicking on element in first row, first column   should go to JSP A
clicking on element in second row , first column should go to JSP B
clicking on element in third row , first column should go to JSP C

In Prepare Action on this jsp I am setting the navigate attribute of RowObj 
to "Preparexxxx.do"

this works fine the way I did.

But was curious to know if this is the right way to do? or is there a better 
way to do the same.

Thanks.

_________________________________________________________________
Express yourself instantly with MSN Messenger! Download today - it's FREE! 
http://messenger.msn.click-url.com/go/onm00200471ave/direct/01/


---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
For additional commands, e-mail: user-help@struts.apache.org


RE: href in a table column

Posted by fea jabi <zy...@hotmail.com>.
can anyone suggest if this is the right way to do? thanks.


>From: "fea jabi" <zy...@hotmail.com>
>Reply-To: "Struts Users Mailing List" <us...@struts.apache.org>
>To: user@struts.apache.org
>Subject: href in a table column
>Date: Wed, 29 Mar 2006 15:08:02 -0500
>
>This is struts related question itself. using displaytag too.
>
>I created an obj whose attributes represent the row obj of a display table.
>
>RowObj
>type
>navigate
>total
>
><display:table name="${data}" id="rows" requestURI="PrepareEntry.do">
>      <!--  Type -->
>      <display:column titleKey="lbl.type">
>             <a href="${rows.navigate}.do"> ${rows.Type} </a>
>      </display:column>
>
>       <!-- Total -->
>       <display:column property="total" titleKey="lbl.total"/>
></display:table>
>
>clicking on each element in first column should navigate to different JSP.
>i.e
>clicking on element in first row, first column   should go to JSP A
>clicking on element in second row , first column should go to JSP B
>clicking on element in third row , first column should go to JSP C
>
>In Prepare Action on this jsp I am setting the navigate attribute of RowObj 
>to "Preparexxxx.do"
>
>this works fine the way I did.
>
>But was curious to know if this is the right way to do? or is there a 
>better way to do the same.
>
>Thanks.
>
>_________________________________________________________________
>Express yourself instantly with MSN Messenger! Download today - it's FREE! 
>http://messenger.msn.click-url.com/go/onm00200471ave/direct/01/
>
>
>---------------------------------------------------------------------
>To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
>For additional commands, e-mail: user-help@struts.apache.org
>

_________________________________________________________________
Express yourself instantly with MSN Messenger! Download today - it's FREE! 
http://messenger.msn.click-url.com/go/onm00200471ave/direct/01/


---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
For additional commands, e-mail: user-help@struts.apache.org