We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 26799
    • 177 Posts
    I get a blank page when I attempt to run a call I’m using in a page below the root|..


    I’ve got a container set up to hold newsletters [docId=109], this container is also within a container (menu structure) so we are two levels below root. On this page I’ve got the call below and it works fine. I’ve got the call below also on the home page [docId=1] two levels above and it breaks the page.

    [!Ditto?&startid=`109`&tpl=`pastNewsLetters`&summarize=`3`&displayArchive=`1`&trunc=`1`&trunclen=`150`&truncText=`more...`!]

    when in the manager I get the following error when the page attempts to preview. I do "NOT" get this when the page attempts to load live. it’s just blank, no source, no blips nothing.


    « MODx Parse Error »
    MODx encountered the following error while attempting to parse the requested resource:
    « PHP Parse Error »

    PHP error debug
    Error: array_values() [function.array-values]: The argument should be an array
    Error type/ Nr.: Warning - 2
    File: /home/nbwco001/public_html/manager/includes/document.parser.class.inc.php(748) : eval()’d code
    Line: 372

    Parser timing
    MySQL: 0.0093 s (11 Requests)
    PHP: 0.0485 s
    Total: 0.0578 s
      • 18397
      • 3,250 Posts
      Try Ditto 2.
        • 18397
        • 3,250 Posts
        As for the error, that is a MODx feature to hide PHP Warnings and Fatal Errors from a non logged in user. That way a hacker could not get useful information from these moments of failure.
          • 26799
          • 177 Posts
          I figured that the error not being displayed on the front end was a security issue, Thanks for that, it’s that kind of thing that makes modx so awesome.

          I looked through the SVN and downloaded Ditto 2, but it still wouldn’t see into the container, however instead of an error it just tells me that the container is empty.
          "no documents found" which is plainly not true, because I’m using the exact same call on the container it’s self and it works fine.

          I also found that Ditto 2 doesn’t pull my "content" TV when parsing the [+content+] PH, so a few instances of Ditto didn’t pull my summery, it does parse the PH [+content+], but it only removed it from output. Thanks for your help Mark, you gotta great app here, I love the new additions will use it in the future.

          by the way the [+#PH+] is Bad, great coding.
            • 18397
            • 3,250 Posts
            "Ditto 2 doesn’t pull my "content" TV when parsing the [+content+] PH,"


            Try the latest SVN version from the Ditto SVN Repo. It should have fixed this.