how to pass value from code to page template

S Ahmed <[email protected]>
Newsgroups gmane.comp.web.freemarker.user
Message-ID <CAG2rwuOoMy_csAQdcq3Etu6QJEiutWe5x5-Zp=L22jR+NvYReg@mail.gmail.com>
I have a page template that I use for all my pages like:

<#macro page title="soem title">
<html>
  <title>${title}</title>
</html>
<body>
..
<#nested>

</body>

</#macro>

Then in my page I am doing:

<#import "/page.ftl" as p>

<@p.page title="some title">

...


What if I wanted to get the title from my java code, and pass it down, is
that possible?

I'm using spring, and my view gets the ModelAndView values, can I set it
from the server side and pass it as a parameter for title?

------------------------------------------------------------------------------
Live Security Virtual Conference
Exclusive live event will cover all the ways today's security and 
threat landscape has changed and how IT managers can respond. Discussions 
will include endpoint security, mobile security and the latest in malware 
threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/

_______________________________________________
FreeMarker-user mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/freemarker-user
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.