Uploaded image for project: 'Apache Freemarker'
  1. Apache Freemarker
  2. FREEMARKER-18

JSP EL function and custom tag with the same name overwrite each other

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Major
    • Resolution: Fixed
    • None
    • 2.3.25-incubating
    • jsp
    • None

    Description

      If a tab library contains both a function and a custom tag with the same name, they will overwrite each other. The one whose XML element in the TLD comes later wins (which for a valid TLD means that the function wins). That's first and foremost a backward compatibility problem, as before 2.3.22 the custom tag always won, because the function was ignored. Starting with 2.3.22 it can happen that you get a function instead of the custom tag, breaking an earlier working template. Also it would be good if we can support both behavior on the same time, be implementing both the TemplateMethodModelEx and the TemplateDirectiveModel interfaces.

      This problem was originally reported here: http://stackoverflow.com/questions/36086025/custom-tags-dont-work-in-freemarker-after-updating-to-version-2-3-22/

      Attachments

        Activity

          People

            ddekany Dániel Dékány
            ddekany Dániel Dékány
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: