Announcement

Collapse
No announcement yet.

9.13 URI Module Changes

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    9.13 URI Module Changes

    I noticed that there was an update to the URI module in the 9.13 release. The major change I noticed is that the urls variable no longer contains every URI for the store on every page but rather contains only the URIs referenced in the page templates.

    However, I have a custom module that includes its own page template content. Within that template's content sections, references to the urls variable seem to be ignored by the URI module. Any references to page URIs from within those content sections have no value unless I separately create a reference to them from within a standard Miva content section.

    For example, we have a page on our stores where users write product reviews. The page code is POWREV. I have written a custom Power Reviews module that has a content section that allows writing the review data to the page. I also reference &mvt:urls:powrev:auto; within that code to link to the "write a review" page. However, after the 9.13 update, this results in a broken link because it has no value. Running TokenList on the page confirms that the urls item doesn't include any URI data for POWREV.

    However, if I go up to my main page content section and assign a variable with the value of l.settings:urls:powrev:auto, then that value gets included in the urls item and my later reference to it within my module's content section works.

    Either this is a bug, or I need to somehow update my module to have my content sections included when determining URIs to populate the urls item.

    I think this is something burch worked on so maybe he can shed some light on it for me. I contacted support already but they didn't really know what to do about it.

    #2
    In 9.13 we're using a new engine mechanism to dynamically load the members of the urls structure as they are accessed. Values for every page should still be available (including your custom page), as long as the urls item is being properly initialized. How are you managing the tokens within your module's content section?

    Comment


      #3
      I'm not doing anything in particular to "initialize" the urls item that I know of, so that may be my missing step here. My module is using the component feature, and on ComponentModule_Initialize it runs the Template_Render function. The reference to the URL item would be part of that template render. Do I need to specifically call a function from the URI module somewhere to have it evaluate my template content before it renders?

      Comment


        #4
        I figured it out. The function I am using to render my template content is using l.all_settings and l.settings as parameters but they weren't set to var, which prevented them from updating as needed.

        Thanks for your help.

        Comment


          #5
          One other tidbit -- The url tokens aren't populating on my Wish List emails. If I use TokenList to view the values, they exist, but when an actual email is sent, they're blank. This doesn't appear to be a problem with the built-in confirmation emails.

          Comment

          Working...
          X