We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 37693
    • 47 Posts
    Hi,

    Retrieving Articles outside of Articles as documented here: http://rtfm.modx.com/display/ADDON/Articles.Retrieving+Articles+Outside+of+Articles works fine.

    However say I have multiple parents e.g.
    &parents=`18,340`
    and I include
    [[!Articles? &container=`18,340`]]
    – this causes a completely blank page. I'm not receiving any PHP errors either.

    Setup:
    - Revo 2.2.5
    - Articles 1.6.3
    - Standard OS X / MAMP

    Many thanks,
    Shaun
      • 10378
      • 375 Posts
      Quote from: shaunmorrison at Nov 05, 2012, 06:23 AM
      Hi,

      Retrieving Articles outside of Articles as documented here: http://rtfm.modx.com/display/ADDON/Articles.Retrieving+Articles+Outside+of+Articles works fine.

      However say I have multiple parents e.g.
      &parents=`18,340`
      and I include
      [[!Articles? &container=`18,340`]]
      – this causes a completely blank page. I'm not receiving any PHP errors either.

      The Articles snippet currently can only handle a single container. You can solve this by using the getResources snippet (available as an MODx extra http://rtfm.modx.com/display/ADDON/getResources):

      [[!getResources?
          &tpl=`NewsRowTpl`
          &parents=`6,71,79,81`
          &showHidden=`1`
          &includeContent=`1`
          &includeTVs=`1`
          &processTVs=`1`
      ]]        
      


      Hint: the showHidden param is necessary as Articles resources are always set to hidden (hide from menu)!

      Greetings,
      Martin
        Freelancer @bitego http://www.bitego.com
        ---
        GoodNews - one of the most advanced and integrated Group Mailer premium add-ons for MODX Revolution!
        More infos here: http://www.bitego.com/extras/goodnews/
        • 37246
        • 128 Posts
        I'm getting a PHP error when I try to do this:

        Catchable fatal error: Argument 2 passed to modX::runSnippet() must be an array, null given, called in /home/*****/public_html/core/components/formz/processors/mgr/tv/output/formz.class.php on line 15 and defined in /home/*****/public_html/core/model/modx/modx.class.php on line 1687


        Thoughts?
          I LOVE MODX! | greyskymedia.com
          • 10378
          • 375 Posts
          Quote from: greyskymedia at Jan 02, 2013, 03:56 PM
          I'm getting a PHP error when I try to do this:

          Catchable fatal error: Argument 2 passed to modX::runSnippet() must be an array, null given, called in /home/*****/public_html/core/components/formz/processors/mgr/tv/output/formz.class.php on line 15 and defined in /home/*****/public_html/core/model/modx/modx.class.php on line 1687


          Thoughts?

          Without a look at your snippet call there isn't much we can do to help you.

          Greetings,
          Martin
            Freelancer @bitego http://www.bitego.com
            ---
            GoodNews - one of the most advanced and integrated Group Mailer premium add-ons for MODX Revolution!
            More infos here: http://www.bitego.com/extras/goodnews/