We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 4437
    • 5 Posts
    I have been told that the ditto command was the way to do it: a newsletter that compiles random recently added pages from the site into a single page, so that it could be eg. printed and mailed out. Someone with mostly basic office skills should be able to perform the collection of relevant entries: this rules out typing the comand. A graphical, drag’n’drop like interface has to be provided. I am fluent in php so I can do some coding if necessary, yet only learning the modx vocabulary.

    How should I make creating the ditto command an office user friendly experience?

    - one way was to start by creating the newsletter page together with a unique tag and then walking the document tree and tagging items with this tag by use of a drop-down menu - this menu will grow huge and clunky as more newsletters are created; it would not allow for sorting the entries on the newsletter page

    - another way maybe was to create a folder and then linking entries from the tree into this folder, the docManager module would make sorting possible. ditto would then just compile all entries of the folder by menuindex.

    additionally, each entry in the newsletter page should be preceded with a header, that is the title of the top folder, where the original is found (eg. specs, news). multiple entries with the same top parent should have their headers collapsed into a single grouping.

    Any ideas? Does this sound usefult to someoby else?

    Peter
      • 3749
      • 24,544 Posts
      If all the news articles are in the same folder, you can write a Ditto call that will just show the most recent n articles.

      ][!Ditto? &startID=`22` &sortBy=`pub_date` &sortDir=`ASC` &total=`10` &paginate=`1` &tpl=`myDittoTplChunk`!]

      Change 22 to the document id of the container document that’s the parent of the news articles. You’ll have to create myDittoTplChunk to format the output. Leave this parameter out at first and Ditto will use the default tpl (look at it to see what yours should look like).

      There are various ways to control which articles go in which newsletter. Probably the easiest would be to just count the number of new ones since the last newsletter and set &total to that value. Your office worker could just edit the value of &total.

      The Ditto parameters are here: http://modxcms.com/ditto_parameters.html
        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
        • 7291
        • 129 Posts
        I had a similar issue with a magazine type site... solved by having specific locations on the website (first article on the pages)
        automatically updated to newsletter template page through various Ditto calls.

        Nothing to do with DItto but would suggest looking into the txnewsletter module...absolutely fantastic.
          [center]-- smiley --[/center]
          [center]New View Media - Custom Website Design[/center]
          [center]Custom Website Design & Marketing = Strategic Business![/center]