我将 MODx Revolution 2.20 版与画廊模块1.4.0 版一起使用。所以,我需要获取文件夹中的图像数量。我用谷歌搜索了它,但我没有找到任何可行的解决方案。
我怎么才能得到它?谢谢。
好的,这就是解决方案。
片段调用
[[!GalleryAlbums? &parent=`5` &showAll=`1` &sort=`rank` &dir=`ASC` &limit=`50` &rowTpl=`b-top-img`]]
b-top-img片段
<!-- p-cover -->
<div class="p-cover [[+id]]">
[[!Gallery? &album=`[[+id]]` &thumbWidth=`300px` &thumbHeight=`300px` &thumbTpl=`b-middle-img`]]
</div>
<!-- /p-cover -->
b-middle-img块
<div class="p"><img src="[[+thumbnail]]" alt="[[+name]]" /></div>