- AdvSearch
- cookieJar
- getYoutube
- aliasid
- AddHeaderfiles
- AjaxUpload
- amazonSES mailing list
- Analytics
- Archivist
- Articles
- Babel
- BannerX
- BannerY
- Batcher
- bdListings
- boilerX
- BreadCrumb
- Breadcrumbs
- BxrExtra
- cachebuster
- CamperManagement
- Church Events Calendar
- Cliche
- ClientConfig
- CMPGenerator
- Collections
- ContextRouter
- CookieList
- CronManager
- cssSweet
- CustomUrls
- Databackup
- Discuss
- DitsNews
- Eletters
- EventManager
- eventsCalendar2
- EventsX
- ExerPlan
- fastField
- FileDownload R
- FileLister
- FirstChildRedirect
- Flexibility
- ForcedPasswdChange
- FormIt
- FormIt2db
- FormitFastPack
- FormSave
- FoundationX
- FX2themebase
- Gallery
- GatewayManager
- gCal
- getDate
- getFeed
- getPage
- getRelated
- getResourceField
- getResources
- getUrlParam
- getRTImages
- getVimeo
- GoogleSiteMap
- GridClassKey
- HandyMan
- Hits
- HitsPage
- HybridAuth
- If
- Image+
- imageHERE
- ImageStyles
- ImportX
- LexRating
- Lingua
- Login
- Loginza
- mChimpX
- MetaX
- mhPayPal
-
MIGX
- MIGX.Backend-Usage
- MIGX.Data-Entry
- MIGX.Frontend-Usage
-
MIGX.Tutorials
- MIGX.Fancybox-images with seperate placeholders in Richtext-Content
- MIGX.Simple opening hours table
- Using resource-specific mediasource and multifile-uploader with MIGX
- MIGX.Varying layout-boxes
- Creating Selectable and Sortable lists for MIGX
- MIGX.sortable resourcelist
- Using resource-specific mediasource and multifile-uploader with MIGX
- MIGX.Using Grid Inline Editing
- MIGXdb
- MinifyX
- miniShop
- modActiveDirectory
- ModDef
- modExtra
- modMobile
- modSwiftMailer
- mxCalendar
- mxExtendedMenu
- mxFormBuilder
- mxHasTvs
- MoneyBird
- ObfuscateEmail-Revo
- PackMan
- PageBreaker
- Peoples
- PHP Tidy (plugin)
- phpThumbOf
- Polls
- POI Manager
- QuickCrumbs
- Quip
- Rampart
- Redirector
- renderResources
- ResourceWatcher
- RezImgCrop
- Rowboat
- sekFancyBox
- sekFormTools
- sekSiteTools
-
sekUserGalleries
- sekUserGalleries.album.items.helper
- sekUserGalleries.album.items.manage
- sekUserGalleries.album.manage
- sekUserGalleries.album.view
- sekUserGalleries.browse.galleries
- sekUserGalleries.directory
- sekUserGalleries.image.information
- sekUserGalleries.search
- sekUserGalleries.users.gallery.manage
- sekUserGalleries.users.gallery.view
- selfLink
- Shopkeeper
- siblingNav
- SimpleSearch
- SiteEditor
- sitemapFriend
- Slideshow Manager
- sLink
- SmartOptimizer
- SmartTag
- StatCache
- SocialLogin
- SocialSuite
- spieFeed
- StaticSaver
- StoreLocator
- SubscribeMe
- SyntaxChecker
- Tagger
- TaggingAtoZ
- tagLister
- TinyMCE
- Upload to Users CMP
- VersionX
- virtuNewsletter
- VisionCart
- Wayfinder
- xFPC
getResources.Category Index Page with Thumbnails
Last edited by Mike Reid on Apr 28, 2014.
Make sure you get phpThumbOf as this does the magic of scaling your thumbnail images.
The TV
We need to create a way to attach an image to each page.
- Create a new TV and name it: page-thumbnail
- Input type: Image
- Select the proper templates in template access and save.
The Chunks
I like to put my snippet calls in a chunk, this way the RTE doesn't turn the & into &
Create a chunk and name it list-docs-thumb
<div class="list-docs thumb grid"> [[!getResources? &parents=`[[*id]]` &tpl=`list-docs-thumb-tpl` &limit=`100` &sortdir=`ASC` &includeTVs=`1` &includeContent=`1` &depth=`0` &sortby=`menuindex` ]] </div><!-- eof list-docs -->?
Create a second chunk for the getResources template, name it: list-docs-thumb-tpl (see what I did there? Naming conventions are your friend.)
<div class="list-item column span-6"> <h2>[[+pagetitle]]</h2> <a href="[[~[[+id]]]]" title="[[+pagetitle]]"> <img src="[[+tv.page-thumb:phpthumbof=`w=153&h=200&zc=1`]]" alt="[[+pagetitle]]" /> </a> <p>[[+introtext]]</p> </div> <!-- eof item -->?
Installation
Now just paste [[$list-docs-thumb]] into any page with child pages and TV's set and away you go.
You should be able to pick up a little bit of speed by omitting the &includeContent parameter if you're not using the content in the template :)
Note that this specific example requires phpThumbOf to be installed to display the images - it can be gotten through the package manager.
Use &tvFilters=`page-thumb==%` to skip resources with empty TV
Suggest an edit to this page on GitHub (Requires GitHub account. Opens a new window/tab).