Uploaded image for project: '[Read Only] - Hippo Site Toolkit 2'
  1. [Read Only] - Hippo Site Toolkit 2
  2. HSTTWO-2710

Allow manual ESI Includes on non-HST navigational servlet/jsp URLs

    XMLWordPrintable

Details

    • New Feature
    • Status: Closed
    • Normal
    • Resolution: Fixed
    • 2.26.07
    • 2.30.00
    • None

    Description

      Eduardo Suarez found this issue. (Thanks a lot!)

      If you set the following options in hst-config.properties to enable manual esi includes, ESI Inclusion on HST Navigation URLs doesn't work. Manual ESI Inclusion on HST Resource URLs still work though.

      Here's a reproduction step:

      (1) Set the following in hst-config.properties:

      1. Flag whether or not ESI fragments should be processed
        esi.default.fragments.processing = true
      2. Flag whether or not ESI processing only for async comp
        esi.processing.condition.async.components = false

      (2) Add 'esifragment' hst page definition:
      <sv:node sv:name="esifragment">
      <sv:property sv:name="jcr:primaryType" sv:type="Name">
      <sv:value>hst:component</sv:value>
      </sv:property>
      <sv:property sv:name="hst:template" sv:type="String">
      <sv:value>esifragment</sv:value>
      </sv:property>
      </sv:node>

      (3) Add 'esifragment' template:
      <sv:node sv:name="esifragment">
      <sv:property sv:name="jcr:primaryType" sv:type="Name">
      <sv:value>hst:template</sv:value>
      </sv:property>
      <sv:property sv:name="hst:renderpath" sv:type="String">
      <sv:value>jsp/components/footer/open-position-within-hippo.jsp</sv:value>
      </sv:property>
      </sv:node>

      (4) Add 'esifragment' sitemap item:
      <sv:node sv:name="esifragment">
      <sv:property sv:name="jcr:primaryType" sv:type="Name">
      <sv:value>hst:sitemapitem</sv:value>
      </sv:property>
      <sv:property sv:name="hst:componentconfigurationid" sv:type="String">
      <sv:value>hst:pages/esifragment</sv:value>
      </sv:property>
      </sv:node>

      (5) Add the following in resources/src/main/webapp/WEB-INF/jsp/components/footer/footer.jsp:
      <div id="ft">
      <!-- SNIP -->
      <p>
      BEGIN ESI INCLUDE –
      <esi:include src="http://localhost:8080/site/esifragment"/>
      – END ESI INCLUDE
      </p>
      </div>

      Even though the hit on http://localhost:8080/site/esifragment shows some text only, the include result by the above esi include element contains the homepage output.

      [1] https://svn.onehippo.org/repos/hippo/hippo-cms7/testsuite

      Attachments

        Issue Links

          Activity

            People

              Unassigned Unassigned
              wko Woonsan Ko (Inactive)
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: