Uploaded image for project: 'Magnolia'
  1. Magnolia
  2. MAGNOLIA-3092

freemarker: support for loading taglibs from classpath resources (jars and folders) instead of WEB-INF/lib only

    Details

    • Type: Improvement
    • Status: Closed
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 4.5
    • Component/s: None
    • Labels:
      None
    • Magnolia Release:
      4.5

      Description

      it would be useful to have freemarker loading taglibs from classpath resources (jars and folders) instead of WEB-INF/lib only.
      I created the MagnoliaTaglibFactory class that, using some code inspired by ClasspathResourceUtil, loads tlds searching in jars and folders derived from classpath. Then, in method FreemarkerHelper.checkTaglibFactory, i changed line
      taglibFactory = new TaglibFactory(servletContext);
      to
      taglibFactory = new MagnoliaTaglibFactory(servletContext);

      If it's fine for you, i can commit it.

      PS: i've submitted the patch to freemarker (http://sourceforge.net/tracker/index.php?func=detail&aid=2954132&group_id=794&atid=100794#)

        Attachments

          Issue Links

            Expenses

              Activity

                People

                • Assignee:
                  fgiust Fabrizio Giustina
                  Reporter:
                  manuelmolaschi Manuel Molaschi
                • Votes:
                  1 Vote for this issue
                  Watchers:
                  2 Start watching this issue

                  Dates

                  • Created:
                    Updated:
                    Resolved:
                    Date of First Response: