We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 999
    • 67 Posts
    Hi all,
    I have a page that displays on its left the list of documents in the folder it belong, like a table of contents.
    When you choose an entry it displays at the right side of the page.

    this works fine. but the are many folders like this. Each folder represents an issue of a magazine.

    how do i tell my page to load content from a specific tv variable from the first document of each folder (which is editorial btw)

    Can i call a page’s content whithout using the id, but using the page title or alias?

    Any help would be deeply aprecciated.

    Alex.
      • 7923
      • 4,213 Posts
      You can use Ditto snippet to list contents from other pages..


        "He can have a lollipop any time he wants to. That's what it means to be a programmer."
        • 999
        • 67 Posts
        Any guidance for this?
          • 31037
          • 358 Posts
          You find the documantation for Ditto here: http://modxcms.com/ditto_documentation.html
            • 999
            • 67 Posts
            When i point Ditto to StartId with another document it fails saying XML Parsing Error: undefined entity
            Location: http://localhost/Mx/index.php?id=51&z=manprev
            Line Number 2, Column 48: <html><head><title>MODx Content Manager &raquo; </title>
            -----------------------------------------------^

            it only works when i point it to a folder that conatins the document from which i want to get the data.

            What if i dont want to point to a folder?
              • 7923
              • 4,213 Posts
              if you need to get just the first document, use the sortBy, sortDir and total parameters to get the document’s in a order that the first one is the one you want and in the total parameter define it to retrieve just 1 document.


                "He can have a lollipop any time he wants to. That's what it means to be a programmer."