karthik G <beginner.tapestry <at> gmail.com> writes:

> I see that asp.net allows you to attach a server side listener to a
> textfield for eg for 'on change event' on the client side. 

This is not the case. This listener is called on the server side.

> Does tapestry allow this? I mean can i configure a listener on a textfield?.  

Not directly. You can use javascript to do that or check if AJAX
can help.

> I see that
> asp.net web forms stores the inital state of the components while rendering
> in a hidden field in rendered HTML. So when the user submits, it reads the
> value that existed while rendering and compares it with the current value
> during submit and based on that decides if the listener needs to be invoked.

Correct. That's why the listener is called on the server side.

> It seems to be creating the page instance (as opposed to tapestry page
> pooling) everytime the rendering / submit happens.

It seems to be the case.

> I also looked at  <at> Persist("client") and i feel that this feature c'd help
> in emulating a similar behaviour in tapestry?

In Tapestry with the use an OGNL expression the TextField will directly
store the new value into a location that you desire, so generally you
don't need to attach a listener to it. If you do need to check if the
value has been changed, yes, you could use a client persistent property.

--
Author of a book for learning Tapestry (http://www.agileskills2.org/EWDT)


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

Reply via email to