We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 30575
    • 8 Posts
    Quote from: mjarecki at May 01, 2006, 06:38 AM

    And is it possible to assign multiple categories to articles and then have Newslisting type summary list based on a specific category?

    Again, in Textpattern (sorry to go on about this, but still getting my head around modX) it is simply a case of typing <txp:article_custom category="photos" offset="0" limit="2" listform="excerptlist" /> or <txp:article_custom author="John" offset="0" limit="2" listform="excerptlist" /> inside a template and an article list by category or author is created.

    Hey Guys,

    I’m another txp refugee trying to get my head around modx. Has anybody answered the query above? I have a few sites that I’m thinking about migrating, but most of them use multiple categories and I can’t see a simple way of implementing this in modx - especially the ability for users to edit the categories themselves.

    thanks in advance...
      • 11975
      • 2,542 Posts
      Hi,

      Newslisting is no more supported you should switch to ditto which has much more features.

      You can achieve news categorization by several ways in MODx.

      The easiest one is to create a folder for each category.

      You could also create a TV named category for instance (select or checkbox) which purpose is to extend the document properties.
      In options values you can add the required categories : Design||Development||Other
      You have to attach this TV to the template used by your documents.

      Once done, You ’ll have a new element in the editing form named "category"

      To display the list of documents with category == Design your ditto call will look something like this

      [[ditto? &startID=`id_of_the_folder_containing_news`&tagData=`tvcategory` &tags=`Design`&summarize=`3` ]]

      :-)
        Made with MODx : [url=http://www.copadel.com]copadel, fruits et l
        • 30575
        • 8 Posts
        Thanks dude. It looks like everything I’ve heard about the ’friendly and responsive’ modx community is true ;-).
          • 10884
          • 6 Posts
          I have made a modifcation for myself; I want to use the menuindex to sort by. Therefore I added || $sortby == "menuindex" in the line below. Myabe it can help someone.

          if (isset($sortby) && ($sortby == "createdon" || $sortby == "editedon" || $sortby == "pub_date" || $sortby == "unpub_date" || $sortby =="deletedon" || $sortby == "menuindex" )) {


          GJB