Reputation: 1010
I need to make a list of users. I am trying to do it this way:
<a href="user/{user.id}">{user.fullname}</a>
But it doesn't evaluate {user.id} so my links are all like "www.example.com/user/{user.id}". What is a correct form how to do it? user.fullname was all right so I supposed that it will work in quotes too but it doesn't.
Upvotes: 0
Views: 207
Reputation: 55798
You mixed Play 1.x
and Play 2.x
templating engines! Take a look to the documentation and included samples!
in Play 2 it would be rather something like:
<a href="@routes.Application.showUser(user.id)">@user.fullname</a>
Upvotes: 2