You can still use Tapestry's link components like DirectLink.
What you need to do is to create a custom link renderer (an implementation of ILinkRenderer) and pass it as the "renderer" parameter.

Check out the source code of the built-in ButtonLinkRenderer (4.0). (If you use Tapestry 3 then looking at DefaultLinkRenderer may help too but ButtonLinkRenderer is very similar to what you want to do!) ButtonLinkRenderer generates a <button> element, you need to change it to <tr>, remove the "type" and "disabled" attributes and you are ready (I think :). Of course if you take this approach then your Foreach component should not generate the <tr> tags.

Hope this helps.
Br,
Norbi

----- Original Message ----- From: "ty renner" <[EMAIL PROTECTED]>
To: <[email protected]>
Sent: Wednesday, June 15, 2005 2:52 AM
Subject: problem with tapestry and javascript, need help!


Hi,

I have a table whose rows are rendered dynamically usinf tapestry
ForEach component. I want to make these rows "hot" so they can be
selected by clicking anywhere on the row. The only way to capture the
onclick event is through javascript and then I want to call a listener
method in the page class. How can this be done? How can I call a
listener method from inside javascript?

Can someone help?

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]





---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to