5ThirtyOne



Mint hidden title modifier [Wordpress]

Apr 16th 2006
One Comment
respond
trackback

Trimmed titles in Mint

Credit to Paul for pointing me in the right direction for cleaning up the titles reflected in my Mint install. Prior to the title modifier, Wordpress’s methodology for displaying the sites title in front of individual post titles was pushing content from view in Mint. Check the screenshot for a visual. Notice the cluttered titles on the left? It’s a lot easier to understand what’s being tracked when titles are readable.

Wordpress users running Mint as their statistical tracking can achieve the same results using the following:

<?php if (is_home()) { ?>
<script type="text/javascript">
// <![CDATA[
var Mint_SI_DocumentTitle = "5ThirtyOne | It's not wheatgrass";
// ]]>
</script>
<?php } else {
$tmpMintTitle = wp_title(”, false);
$tmpMintTitle = substr($tmpMintTitle, 2, strlen($tmpMintTitle));
?>
<script type="text/javascript">
// <![CDATA[
var Mint_SI_DocumentTitle = "<?php echo $tmpMintTitle ?>";
// ]]>
</script>
<?php } ?>
<script src="/mint/?js" type="text/javascript">
</script>

Note that you must change 5ThirtyOne | It’s not wheatgrass to reflect your own page title. Shaun Inman’s original Mint: Overriding Page Titles covers the official title modifier.



One Comment

  1. Abe Lincoln

    I just wanted to say thanks. This solved my only problem(so far) with Mint.
    Love the site btw.

Incoming Links



Leave a Reply

Comments may be held for moderation. If your comment does not appear immediately, do not repost. I reserve the right to remove any inappropriate or off-topic comments. Please use the forum if your comment is not appropriate for the current article.

Flickr Visit »

  • Roof top
  • Burnside
  • 6th & Alder St.
  • Mossy stairs
  • Sidewalk
  • Stones
  • Shadows
  • Rock floor
  • Doughnut racks
  • Voodoo Doughnuts
  • Syl Chinese Garden
  • Syl showing the goods
  • Nuts & Oreo
  • Reflected
  • Voodoo menu
  • Street vendors
  • Voodoo Doughnuts
  • Passing
  • Japenese Garden
  • Zig zag bridge