Praveen Kumar
2013-10-27 12:58:48 UTC
Hi All.
Freemarker layout example.
Example from (http://richardbarabe.wordpress.com/2009/03/19/freemarker-a-brief-example/)
<#macro myLayout title="FreeMarker example">
<html> <head>
<title> ${title} </title>
<#include "header.ftl"/>
</head>
<body>
<div class="menus">
<#include "menu.ftl"/>
</div>
<div class="body">
<#nested/>
</div>
<div class="footer">
<#include "footer.ftl"/>
</div>
</body>
</html>
</#macro>
<#import "layout/defaultLayout.ftl" as layout>
<@layout.myLayout "Home page">
<div><h1>Hello Freemarker</h1></div>
</@layout.myLayout>
Is the above approach and using Apache tiles with freemarker have same behavior in page rendering process.
If there are any differences in page rendering logic . Please help me to understand the differences and which one is better approach.
Thanks a lot.
Freemarker layout example.
Example from (http://richardbarabe.wordpress.com/2009/03/19/freemarker-a-brief-example/)
<#macro myLayout title="FreeMarker example">
<html> <head>
<title> ${title} </title>
<#include "header.ftl"/>
</head>
<body>
<div class="menus">
<#include "menu.ftl"/>
</div>
<div class="body">
<#nested/>
</div>
<div class="footer">
<#include "footer.ftl"/>
</div>
</body>
</html>
</#macro>
<#import "layout/defaultLayout.ftl" as layout>
<@layout.myLayout "Home page">
<div><h1>Hello Freemarker</h1></div>
</@layout.myLayout>
Is the above approach and using Apache tiles with freemarker have same behavior in page rendering process.
If there are any differences in page rendering logic . Please help me to understand the differences and which one is better approach.
Thanks a lot.