A container tag which iterates (loops) over a list of Assets from one or more blogs.
<mt:Assets> <mt:AssetLabel>: <mt:AssetDescription> </mt:Assets>
This container tag may contain any Asset function template tags.
- intergers less than or equal to “100”
auto- which selects the most aesthetically pleasing number of items per row based on the total number of assets. For example, if you had 18 total assets, three rows of six would publish, but for 16 assets, four rows of four would publish.
Selects assets uploaded by a single author.
Specify author’s username.
<mt:Assets author="beau"> <!-- tags here --> </mt:Assets>
Selects assets created in the last number of days specified.
<mt:Assets days="3"> <!-- tags here --> </mt:Assets>
Selects assets by file extension.
Supports a comma-delimited list of file extensions.
<mt:Assets file_ext="gif, mp3, pdf"> <!-- tags here --> </mt:Assets>
Selects assets by asset type.
<mt:Assets file_ext="image"> <!-- tags here --> </mt:Assets>
Supports a comma-delimited list of asset types:
file(new in MT5)
Limits the selection of assets to the specified number.
<mt:Assets lastn="3"> <!-- tags here --> </mt:Assets>
A positive integer to limit results.
<mt:Assets limit="3"> <!-- tags here --> </mt:Assets>
Used in conjunction with the
sort_by attribute when sorting by “score”. The namespace identifies the method of scoring to use in sorting assets.
Used in coordination with
lastn, starts N assets from the start of the list. N is a positive integer.
<mt:Assets lastn="1"> <!-- special treatment for first asset --> </mt:Assets> <mt:Assets lastn="9" offset="1"> <!-- alternate treatment for next 9 assets --> </mt:Assets>
Sort assets by value.
<mt:Assets sort_by="label"> <!-- asset tags --> </mt:Assets>
Selects assets with particular tags.
Supports expressions such as “interesting AND featured”).
<mt:Assets tag="foo AND bar"> <!-- tags here --> </mt:Assets>
ignore_archive_context modifier is set to
1, assets are loaded without regard for the current archive in context. This modifier was added to Movable Type 6.0.4.
This container tag loop lists all assets in the current blog that have the favorite tag.
<mt:Assets lastn="10" type="image" tag="favorite"> <a href="<mt:AssetURL>"> <img src="<mt:AssetThumbnailURL height="70">" alt="<mt:AssetLabel escape="html">" title="<mt:AssetLabel escape="html">" /> </a> </mt:Assets>
This container tag loop lists all assets associated with a Movable Type 5.x or 6.x website or any one of the blogs that is owned by that website.
<mt:Assets include_blogs="children" include_with_website="1"> <mt:AssetLabel>: <mt:AssetFilePath><br /> </mt:Assets>
- Template Loop Meta Variables offer conditionals for odd, even, first, last, and counter.
- MultiBlog template tags let you aggregate and publish assets from one or more blogs in your system, and apply criteria for filtering which assets are displayed.
- On the Edit Asset screen in the sidebar is an “Appears In…” widget that shows which Entries and Pages use that Asset. There are no Movable Type core template tags to publish this association, however the Extra Tags plugin adds this capability with the AssetEntries template tag.