Advanced Templates: TypeList Tags

The TypeList tags are for displaying data from your TypeLists.

MTListInclude

The MTListInclude tag displays your TypeLists as pre-formatted html code blocks in an advanced template. The list items are enclosed automatically in <li>list item</li> markup and the display of the list is set in the advanced configuration for the TypeList.

Use the name attribute to specify the TypeList to display:

<$MTListInclude name="TypeList Name"$>

The TypeList Name is the name you gave the TypeList and is set in the configuration for the TypeList. The name is case sensitive so use it in the tag exactly as it is entered in the TypeList configuration.


You can also use the MTUserLists container to include all of the lists that you have selected to display on your About Page. The name attribute is not used, the MTListInclude tag is surrounded by the MTUserLists container instead:

<MTUserLists><$MTListInclude$></MTUserLists>

MTList

These tags give you full control of the TypeList display. The MTList container loops through the list items and displays each using the MTListItem tag.

Use the name to specify the TypeList to display:

<MTList name="TypeList Name">
<$MTListItem$> <br />
</MTList>

MTListItem Fields

Use field with the <$MTListItem$> tag to specify the field that you would like to display from the TypeList. Each list type (People, Link, Reading, Music) has its own set of valid fields:

People TypeList
Name: <$MTListItem field="name"$>
Site Name: <$MTListItem field="site_name"$>
Homepage: <$MTListItem field="htmlurl"$>
Email Address: <$MTListItem field="email"$>
One-Line Bio: <$MTListItem field="notes"$>

Display a list of people with the Site Name linked and the One-Line Bio as the link tooltip:

<h2>Friends</h2>
<ul>
<MTList name="TypeList Name">
<li>
<a href="<$MTListItem field="htmlurl"$>" title="<$MTListItem field="notes"$>">
<$MTListItem field="site_name"$></a>
</li>
</MTList>
</ul>
Link TypeList
Link title: <$MTListItem field="title"$>
Link URL: <$MTListItem field="url"$>
Notes: <$MTListItem field="notes"$>

Display a list of links that use the link title as the link and open in a new window:

<h2>Links</h2>
<ul>
<MTList name="TypeList Name">
<li>
<a href="<$MTListItem field="url"$>" target="_new">
<$MTListItem field="title"$></a>
</li>
</MTList>
</ul>
Reading TypeList
Title: <$MTListItem field="title"$>
Author: <$MTListItem field="author"$>
Notes: <$MTListItem field="notes"$>
Rating as 1 - 5: <$MTListItem field="rating"$>
Rating as *: <$MTListItemRating$>
ASIN: <$MTListItem field="asin"$>
Amazon URL: <$MTListItemURL$>
Amazon image: <$MTListItemImage$>

Display a list with the thumbnail of the book, the title of the book, and the rating as stars:

<h2>Books</h2>
<ul>
<MTList name="TypeList Name">
<li>
<a href="<$MTListItemURL$>"><$MTListItemImage$></a> <br />
<$MTListItem field="title"$> <br />
<$MTListItemRating$>
</li>
</MTList>
</ul>
Music TypeList
Song: <$MTListItem field="song"$>
Artist: <$MTListItem field="artist"$>
Album: <$MTListItem field="album"$>
Notes: <$MTListItem field="notes"$>
Rating as 1 - 5: <$MTListItem field="rating"$>
Rating as *: <$MTListItemRating$>
Amazon URL: <$MTListItemURL$>
Amazon image: <$MTListItemImage$>

Display a text list of albums with the artist as the tooltip and also display the notes for the item:

<h2>Albums</h2>
<ul>
<MTList name="TypeList Name">
<li>
<a href="<$MTListItemURL$>" title="<$MTListItem field="artist"$>">
<$MTListItem field="album"$> </a> <br />
<$MTListItem field="notes"$>
</li>
</MTList>
</ul>

Copyright © 2003-2005 Six Apart

[top]