evanwong
evanwong

Reputation: 5134

In playframework 2.0, how do I use the session object in templates?

In playframework 1.x, session is just an implicit object in templates but it seems like it is gone in playframework 2.0. Is there a way for me to use the session object in the templates?

Thanks.

Upvotes: 4

Views: 2046

Answers (1)

aaberg
aaberg

Reputation: 2273

If I remember right, you should be able to get a value stored in session like this:

@session.get("mySessionVar")

Upvotes: 6

Related Questions