<$mt:CategoryBasename$>

Produces the dirified basename defined for the category in context.

Attributes

default

A value to use in the event that no category is in context.

separator

Valid values are dash “-” (default) and underscore “_”. Specifying an underscore will convert any dashes to underscores. Specifying a dash will convert any underscores to dashes.

Example

If the basename of the category “News & Press” is news_press then this tag will output the dashed version news-press:

<$mt:CategoryBasename separator="-"$>

For an overview of how to use category tags like mt:CategoryBasename, check out Managing Categories in Movable Type.

This page was last updated on 2009-06-23, 11:49.

2 Notes

The link for "Managing Categories in Movable Type" in the last sentence needs to be updated to:

http://www.movabletype.org/documentation/administrator/managing-blogs/managing-categories.html

link to "Managing Categories in Movable Type" is a 404.

Leave a note

Have a question? Please use the MT Forums. Notes submitted on documentation should pertain to tips & hints regarding documentation. Your note may be removed once its contents have been integrated into the body of the page.