Grails way for rendering the GSP templates: The tmpl namespace.

01 / Oct / 2010 by Chandan Luthra 3 comments

Today while working on a project, I paired up with my colleague (Uday)  and we found that we can render a gsp template in a different manner also. Grails provide us a “tmpl” namespace for rendering the GSP templates.

The old way that we use to render a gsp template


The other way for  rendering the template.


Like me, you also must be wondering that if the template is in some other path like some shared folder “/shared/templateName” then how this <tmpl/> would work?

e.g.


The answer is: <tmpl:/shared/templateName/>


* you can find the documentation for this on http://www.grails.org/doc/latest/guide/single.html

Concerns, comments or suggestions are always welcome.
Cheers!!!!!
~Chandan Luthra~
chandan(aT)intelligrape(dOt)com

FOUND THIS USEFUL? SHARE IT

Tag -

Grails Groovy gsp

comments (3)

  1. nanaherbal

    I have been exploring for a bit for any high quality articles or blog posts on this sort of space . Exploring in Yahoo I ultimately stumbled upon this website. Studying this info So i’m happy to convey that I’ve a very just right uncanny feeling I came upon just what I needed. I most for sure will make sure to do not put out of your mind this web site and provides it a look on a relentless basis.

    Reply

Leave a Reply

Your email address will not be published. Required fields are marked *