We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 4429
    • 429 Posts
    Just a quckie.

    what is the call for the current document? you know something like [+id+] or [~[id]~]

    I have a ditto call that I will be using freqently on a site, so was planning to pop this into a chunk. the problem being that the parent document ID will be different on each page the chunck is called. But if there is a call like the above that relates to the current page, then that will solve the problem

    thanks
      • 26931
      • 2,314 Posts
      would [+parent+] work in your case?
        • 36592
        • 970 Posts
        Or [*id*] ?
          • 3749
          • 24,544 Posts
          I’m not clear on what you want, but maybe this will help.

          In regular content or in a template [*id*] is the ID of the current page, [*parent*] is the ID of the current page’s parent.

          In a Ditto Tpl chunk, [+id+] will be the ID of the document Ditto is currently grabbing, [*id*] will be the ID of the page with the Ditto tag on it.
          In a Ditto Tpl chunk, [+parent+] will be the ID of the parent of the document Ditto is grabbing, [*parent*] will be the ID of the parent of the page with the Ditto tag on it.

          That’s for MODx Evolution. In Revolution, the principle is the same but the tags are:

          [[+id]]
          [[*id]]
          [[*parent]]
          [[+parent]]

            Did I help you? Buy me a beer
            Get my Book: MODX:The Official Guide
            MODX info for everyone: http://bobsguides.com/modx.html
            My MODX Extras
            Bob's Guides is now hosted at A2 MODX Hosting