We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 50628
    • 10 Posts
    Hi, could someone help me with that?
    I have parent container with ID=1 and some news resources created as childs.
    How could i display content of 3 latest child when i'm opening parent link?
    I've installed getResources and try to add
    [[!getResources? &parents=`[[*id]]`]]
    to parent container content, and it doesn't work. [ed. note: prev59 last edited this post 11 years, 1 month ago.]
      • 36613
      • 328 Posts
      I must create a chunck with the item code, example name item_row_tpl:
      <li><a href="[[~[[+id]]]]" title="[[+pagetitle]]">[[+pagetitle]]</a></li>


      [[getResources? 
        &parents=`[[*id]]`
        &limit=`3`
        &depth=`0` 
        &tpl=`item_row_tpl`
      ]]
        • 28042 ☆ A M B ☆
        • 24,524 Posts
        Don't forget to put the <ul> tags around the getResources snippet, or you'll have an invalid list.
          Studying MODX in the desert - http://sottwell.com
          Tips and Tricks from the MODX Forums and Slack Channels - http://modxcookbook.com
          Join the Slack Community - http://modx.org
          • 50628
          • 10 Posts
          I've added new chunk with name 'news' and doesn't help. Tried to use &debug=`1` and it also shows nothing
          If i use [[!getResources:default=`Not found`? &parents=`1` &tpl=`news`]] , i'll get 'Not found' string [ed. note: prev59 last edited this post 11 years, 1 month ago.]
            • 50628
            • 10 Posts
            Solved, &showHidden=`1`