We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 18397
    • 3,250 Posts
    Ditto has a dedicated sub-forum. Please create a new topic there. This topic is now locked.

    This is an auto-generated support/comment thread for Ditto.

    Use this forum to post any comments about this addition or any questions you have regarding its use.

    Brief Description:
    Ditto 1.0.1: the nimbler, faster, better-named and even more flexible offspring of NewsListing.

    Documentation:
    http://modxcms.com/ditto_documentation.html
      • 22815
      • 1,097 Posts
      Welcome to the new official thread.

      If you have a question about Ditto, it may have already been answered. As well as this thread, please read the following threads:

      Pre-Repository Ditto 1.01 Thread
      Ditto 1.0 Thread

      and also look in
      Modules, Plugins & Snippets » News, Blogs & Articles

      as well as trying the search facility.

      Some older issues may be in threads about Ditto’s fore-runner, NewsListing.
        No, I don't know what OpenGeek's saying half the time either.
        MODx Documentation: The Wiki | My Wiki contributions | Main MODx Documentation
        Forum: Where to post threads about add-ons | Forum Rules
        Like MODx? donate (and/or share your resources)
        Like me? See my Amazon wishlist
        MODx "Most Promising CMS" - so appropriate!
        • 16610
        • 634 Posts
        Bugs?

        - There is something odd going on with &truncLen parameter and
        -tags in documents. If you have a document with plenty of
        -tags the document wont truncate at all.

        Solution, I think...
        ditto.class.inc.php:
        line 252 should be +3 and line 257 should be -2

        After that correction everything seems to be fine again.

        - &archiveText parameter is not working, correction to line 96 on Ditto snippet (capital T -letters).

        - &total parameter is missing from documentation. Parameter still works.
          Mikko Lammi, Owner at Maagit
          • 18397
          • 3,250 Posts
          Thank you for finding the archiveText typo. This has now been fixed in my development code. The other bugs you mentioned have already been reported in the main Ditto topic and have been fixed for the next release.
            • 29988
            • 89 Posts
            I had troubles running Ditto Version: 1.0.2, there is:

            if (count($resource) < 1) { return $emptyText."\n"; }

            but this count() returns 1 of $resource is false, so I’ve changed it to:

            if ((count($resource) < 1) || (!$resource)) { return $emptyText."\n"; }

            I’m running PHP 5.x (5.1.2 afaik), so there may have been some minor changes...
              • 18397
              • 3,250 Posts
              Thanks, this change has been checked into Ditto’s SVN. (public assess soon!)
                • 36747
                • 138 Posts
                So Ditto 1.0.2 is buggy?

                cheers
                eemi
                  patagonia, argentina
                  • 18397
                  • 3,250 Posts
                  There is only 1 known bug (minor) in Ditto 1.0.2. How does this constitute buggy?
                    • 7923
                    • 4,213 Posts
                    Is it possible to define what fields should be in the JSON output from documents? I’d like to do a GoogleMap snippet that would use Ditto’s json output for feed to pin the map, but I need more of the document fields to be in the output. Didnt try it yet, but I peeked at the code and saw only title, description and summary/content fields coming to the json output. Would it be possible for example to define additional tv fields to have in the output, or some of the document fields, like menutitle and longtitle? and maybe both summary and content fields?


                      "He can have a lollipop any time he wants to. That's what it means to be a programmer."
                      • 22302
                      • 42 Posts
                      I get this error:
                      MODx encountered the following error while attempting to parse the requested resource:
                      « PHP Parse Error »
                       
                      PHP error debug
                        Error: 	Invalid argument supplied for foreach()	 
                        Error type/ Nr.: 	Warning - 2	 
                        File: 	/home/.fenimore/hunder/benoitdeziel/assets/snippets/ditto/ditto.class.inc.php	 
                        Line: 	84	 
                        Line 84 source: 	foreach ($modx->documentMap as $mapEntry) {
                      


                      when installing the new Ditto.

                      I went back with the older one but I get the same error. I was working before.
                        [b]Benoit Deziel[b]

                      This discussion is closed to further replies. Keep calm and carry on.