Jahia Dev Forum > Groovy versions...

0 (0 Good)
0 (0 Bad)

Groovy versions of JSP taglib methods

by  tlefevre »  2012/09/26 13:09

I am working on new components for a customer and I prefer to develop these in groovy scripts. So far I have managed with just plain groovy files, but for some advanced functionality I need to be able to access some of the methods exposed via the JSP taglibs but as I am developing them in groovy ... well, obviously I need to access these from groovy. How would I achieve something like: in groovy? Thanks in advance!
  • Groovy versions of JSP taglib methods
    2012/09/26 13:09

    tlefevre I am working on new components for a customer and I prefer to develop these in groovy scripts. So far I have managed with just plain groovy files, but for some advanced functionality I need to be able to access some of the methods exposed via the JSP taglibs but as I am developing them in groovy ... well, obviously I need to access these from groovy. How would I achieve something like: <template:module node="${childNode}"/> in groovy? Thanks in advance!

  • Number of messages  1
    Registration date Sep 26, 2012
    0 (0 Good)
    0 (0 Bad)

    Re: Groovy versions of JSP taglib methods

    by  dgriffon »  2014/01/02 09:36

    Hello,

    Within the groovy script  you have access to the same objects as the jsp ones like

    currentNode, renderContext or renderContext

    but the jsp tags are not available. Still, you can get the java tag code, then use it directly in your groovy script.  

    best regards

    David Griffon

    David Griffon (dgriffon)

    Number of messages  76
    Registration date
    Contact
    Share
    Feedback

    Get in touch

    Whether you are a current user or if you are just evaluating Jahia, we are here to help.

    Contact us

    Share this page