Skip to content

_carousel

Wayne Roddy edited this page Oct 14, 2015 · 2 revisions

A carousel is a basic horizontal row of page summary cells

The MXT Feature Call to be placed where you want it rendered:

[[$mxt.feature_carousel_[[++mxt.theme]]]]

that contains this:

[[[[*carousel_ids:is=``:then=`-`:else=``]]getResources? 
    &resources=`[[*carousel_ids:is=`default`:then=`[[++mxt.default_carousel]]`:else=`[[*carousel_ids]]`]]` 
    &tpl=`tpl.feature_carousel_[[++mxt.theme]]`
    &sortdir=`ASC` 
    &tplFirst=`tpl.feature_carousel_first_[[++mxt.theme]]`
    &tplLast=`tpl.feature_carousel_last_[[++mxt.theme]]`
    &includeTVs=`1` &processTVs=`1` &tvPrefix=`tv.`
]]

Which says if you have something in the TV continue. If you put "default" get the default ID's from the context setting, else get the ID's from the Resource.


Layout Chunks: The getResources call is using a "first" and "last" template not only to set specific classes on <li> but for the ability to wrap multiple <div> containers and navigations.

Clone this wiki locally