We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 31601
    • 57 Posts
    Try and keep this as clear as possible-

    I’m using a template that includes two calls to ditto for links and an archived folder. The chunk calls are in the template. Then I have a document that makes a call to ditto to show a list of blog entries. This document is paginated. Pagination works properly- when clicking on next or prev links, the right documents load. However, whenever I click on the next link, neither of the ditto calls in the template output any data. Both ditto calls in the template are called uncached. The call is also called uncached on the page. Neither of the calls to ditto in the template are are loaded in the call in the page- only in the template. I do have calls to Jot in the template for ditto in the document, but I do not call this template in the files loaded in the site template. I know this is a bit complex, but wondering if anybody has ever had this problem?

    Any help is GREATLY appreciated. sad

    Never mind! Realized I have to use the id parameter- that fixed everything up nicely! GREAT Ditto support site, BTW, to whomever put it together!!

      • 2091
      • 44 Posts
      I’m having a similar problem and I have read posts about using the id parameter, but I’m not really sure how that’s supposed to work.

      I have two Ditto calls in one chunk. The first one pulls a list of a few featured articles. The second call pulls a hundred or so articles. When I leave the first page of articles, the first call stops displaying anything.

      Here are my two Ditto calls.
      <br />[!Ditto? &startID=`9` &tpl=`Featured` &tagData=`tvtags` &tagDelimiter=`, ` &tagMode=`onlyTags` &tags=`Featured` ]]<br /><br />[!Ditto? &startID=`9` &tplAlt=`AltRow` &tpl=`Row` &tagData=`tvtags` &tagDelimiter=`, ` &tagMode=`onlyTags` &tags=`Articles` &summarize=`20` &paginate=`1` &paginateAlwaysShowLinks=`1` &dateFormat=`%B %d, %Y` ]]


      Any help would be greatly appreciated.
        • 18397
        • 3,250 Posts
        @virgil: Thank you!

        @ArkWeb:
        If you plan on having multiple Ditto calls using pagination on one page or using Reflect in your template make sure you use the &id parameter. Set it to a unique string and then update your placeholders to the format [+id_placeholder+]. Also, If you have PHx installed you will need to call Ditto cached on an uncached page.
          • 2091
          • 44 Posts
          Thanks Mark.

          I added &id=`featured` to my first call. Then changed the &tpl chunk to this: <a href="[~[+featured_id+]~]"> [+featured_title+]</a>

          <p>[+featured_introtext+]</p>

          And now no articles show up there at all.
            • 18397
            • 3,250 Posts
            The id prefix goes for MODx placeholders like [+total+], [+pages+], etc that are set by Ditto. You don’t need to prefix the templates.
              • 2091
              • 44 Posts
              Thanks! It works perfectly!