MovableBlog: MT Archives Indicator
March 15, 2003
As for the code that I use for the archives indicator (click on a monthly archive in the sidebar and it not only disables the link for the archive, but changes the background colour of the text), here it is.
<p><b>Archives</b><br />
<MTArchiveList archive_type="Monthly">
<?php
if (!eregi("<$MTArchiveDate format="%Y_%m"$>", $_SERVER['PHP_SELF']))
print "<a href=\"<$MTArchiveLink$>\"><$MTArchiveTitle$></a>";
else print "<span class=\"greyback\"><$MTArchiveTitle$></span>";
?><br />
</MTArchiveList>
</p>
It exists on every page with a sidebar (with a few exceptions) because the above code is in a Template Module called "Archives Listing". I then put <$MTInclude module="Archives Listing"$> in where the sidebar appears in my regular (i.e. Index, Individual and Monthly) templates.
In your CSS, you will need something like this:
.greyback
{
background-color: #CCCCCC;
}