Java Mailing List Archive

Home » FreeMarker-user »

[FreeMarker-user] help in understand how to reference my objects in
 my view

S Ahmed


Replies: Find Java Web Hosting

Author LoginPost Reply
I have a UserSession object that I add into my model like:

UserSession userSession = get....

ModelAndView mav = new ModelAndView("..");

mav.add("session", userSession);

return mav;

Now in my index.ftl page I want to do this:

if userSession.isLoggedIn
end if

How do I do that using freemarker?

I tried this:

<#if session.isSignedIn>

But I get an error saying that session.isSignedIn has to return true/false.  Is does return true/false, so what is wrong?

For Developers, A Lot Can Happen In A Second.
Boundary is the first to Know...and Tell You.
Monitor Your Applications in Ultra-Fine Resolution. Try it FREE!
FreeMarker-user mailing list
©2008 - Jax Systems, LLC, U.S.A.