We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 36830
    • 140 Posts
    Simple getResources call for getImageList snippet isn't working; produces no result. The getImageList works on its own so I think the problem is with the getResources call.

    getResources on page:

    [[!getResources? 
      &parents=`118`
      &includeContent=`1` 
      &includeTVs=`1` 
      &processTVs=`1`
      &showHidden=`1`
      &tpl=`hpWorkThumbsMigxTpl`
      &tplLast=`hpWorkThumbsLastTpl`
      &limit=`6`]]
    


    hpWorkThumbsMigxTpl:

    <div class="large-4 medium-4 small-6 columns collapse">
    [[!getImageList? 
      &docid=`[[+id]]`
      &tvname=`hpWorkThumbsTv` 
      &tpl=`hpWorkThumbsTpl`
      &limit=`1`]]
    </div>
    


    tpl:

    <div class="overlay-container defer-image image-ratio:10x7">
    			<div data-src="[[+slider-image:phpthumbof=`w=530&h=400&zc=1&q=90`]]" alt="[[+cstitle]]"></div>
    				<div class="gallery-image-title">
    					<p class="tp related-title hide-for-large-up">[[+cstitle]]<br>
    					<span class="gallery-image-tags">[[+resource.description]]</span></p>
    				</div>
    		<div>
    


    Error Log:

     [2015-09-29 06:08:50] (ERROR @ /index.php) context for 118 is web
    [2015-09-29 06:08:50] (ERROR @ /index.php) SELECT `modResource`.`id`, `modResource`.`type`, `modResource`.`contentType`, `modResource`.`pagetitle`, `modResource`.`longtitle`, `modResource`.`description`, `modResource`.`alias`, `modResource`.`link_attributes`, `modResource`.`published`, `modResource`.`pub_date`, `modResource`.`unpub_date`, `modResource`.`parent`, `modResource`.`isfolder`, `modResource`.`introtext`, `modResource`.`content`, `modResource`.`richtext`, `modResource`.`template`, `modResource`.`menuindex`, `modResource`.`searchable`, `modResource`.`cacheable`, `modResource`.`createdby`, `modResource`.`createdon`, `modResource`.`editedby`, `modResource`.`editedon`, `modResource`.`deleted`, `modResource`.`deletedon`, `modResource`.`deletedby`, `modResource`.`publishedon`, `modResource`.`publishedby`, `modResource`.`menutitle`, `modResource`.`donthit`, `modResource`.`privateweb`, `modResource`.`privatemgr`, `modResource`.`content_dispo`, `modResource`.`hidemenu`, `modResource`.`class_key`, `modResource`.`context_key`, `modResource`.`content_type`, `modResource`.`uri`, `modResource`.`uri_override`, `modResource`.`hide_children_in_tree`, `modResource`.`show_in_tree`, `modResource`.`properties` FROM `modx_site_content` AS `modResource` WHERE  ( modResource.parent IN (118) AND `modResource`.`deleted` = 0 AND `modResource`.`published` = 1 )  ORDER BY publishedon DESC LIMIT 6 

    • That should work, it's been the way to do it for some time now http://forums.modx.com/thread/69899/solved-managing-lists-of-lists---migx-and-getresources-usage

      Maybe that getImageList shouldn't be cached?
        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
        • 36830
        • 140 Posts
        Nope. Still not working...
          • 37105
          • 194 Posts
          Just for your information: the two line in the error log mentioning errors are not quit errors but messages as Jason Coward (opengeek) mentioned in other post.

          opengeek Reply #3, 3 years, 6 months ago
          It's just an informational log message when you turn debug on in the snippet. It is not an error.

          http://forums.modx.com/thread/74755/getresources-produces-context-errors#dis-post-416063
            Codeplaza Webdesign: for professional websites at low cost