On Mon, 05 Nov 2012 16:21:59 -0200, mateen <[email protected]> wrote:

Hi,

Hi!

I am creating a simple application where a user logs in. On the next and all subsequent pages, i want to display the user information. How can i set and then read the values of these beens both in the view as well as the backing java file ?

Please check http://tapestry.apache.org/session-storage.html. Basically, if your user class is User, add @SessionState(create = false) private User user; fields in your pages. All them will refer to the same User instance in the session. When you log in, just make user = xxx; where xxx is the User object representing the user.

Do you really want to change object fields values from the view (aka templates)? Unless you're using a form, this is a huge bad practice.

--
Thiago H. de Paula Figueiredo

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to