This Movable Type plugin implements a set of template tags for displaying a portion of a template conditionally, depending on the results of a comparison between values. The values compared can be literal strings or numbers, or they can be pieces of MT template code that the plugin will build and evaluate, using the result in the comparison.
- Display different text in the Comments link for each entry depending on how many comments have been posted
- Use a different display format for entries by a particular author or set of authors
- Within a category listing on a category archive page, display the current page's category differently from the rest
- Display different text on an entry depending on what time of day it was entered ("morning," "afternoon," etc.)
These tags are intended for doing straight comparisons of equality and inequality. If you want to compare things against regular expressions (for instance, finding out whether a string contains another string), you should try Brad Choate's powerful and flexible Regex plugin. (The MTIfMatches tag in that plugin overlaps somewhat in functionality with the MTIfEqual and MTIfNotEqual tags in this one.)