Today I am a genius
Rebecca tells me that I would be amazed at how often I say things like this while sitting at my keyboard:
"I'm a genius! Wait, wait...no. I'm an idiot. Ah, it doesn't like the div tag. Ahah! I amaze myself! What I've got going for myself, Rebecca, is dogged perseverance. Wait, no! Damn it! I'm an idiot...."
And this goes on and on..... Currently I believe myself to be a genius because I have managed to make changes to my category archives page with far greater speed and ease than I would have expected. As it stands now, rather than having a category page that lists in reverse chronological order all of the posts tagged as belonging to that category--highly undesirable because the category pages inevitably would become much too long--I now have category pages that: -- list the posts by date and title -- show the number of TypePad comments submitted for each post -- show the various categories in which each post is categorized -- display a brief excerpt from the post Now the category pages will still get long over time, but it shouldn't be the same dreadful problem it would have been. I accomplished all this by manipulating various tags as described in the TypePad knowledge database. Here's what I did in detail for those interested. Remember that in order to do this you have to be using Advanced Templates in TypePad Pro. I'll put notes to you between these marks: ***[ and ]***. In the Category Archives template I replaced this line: <$MTWeblogIncludeModule module="entry-list"$> which calls up a list of posts, with all of this:
***[note at top of page begins here]*** <b>Category Archive Pages</b><br /> Note that older posts (before June, 2006) listed here as having no comments may in fact have Haloscan comments attached to them. Go to the individual posts and click the Haloscan link, if there is one, to view older comments. <br /><br /> Skip to a different category page: ***[[this is a hack for putting category archives in a drop-down menu; found here]]*** <div class="module-content"> <ul class="module-list"> <form> <select style="width:150px; margin: 0px 0px 10px 5px; font-family: verdana, Arial, sans-serif; font-size: 11px;color:#333333;" onChange="document.location=options[selectedIndex].value;"> <option value="">archives by category</option> <MTArchiveList archive_type="Category"> <option value="<$MTArchiveLink$>"><$MTArchiveTitle$> (<$MTArchiveCount$>)</option> </MTArchiveList> </select> </form> </ul> </div> <br /> ***[[end of drop-down menu hack]]*** ***[note at top of page ends here]*** ***[my google ad code goes here]*** <MTEntries> <b><$MTEntryDate format="%b %e, %Y"$>: <a href="<$MTEntryPermalink$>"><$MTEntryTitle$></a></b><br /> Comments: <$MTEntryCommentCount$> | <MTEntryIfCategories>Categories: <MTEntryCategories glue=", "> <MTBlogIfArchives archive_type="Category"> <a href="<$MTCategoryArchiveLink$>"><$MTCategoryLabel$></a> <MTElse><$MTCategoryLabel$></MTElse> </MTBlogIfArchives></MTEntryCategories></MTEntryIfCategories> <br /> <div style="padding-left:10px;"><i><$MTEntryExcerpt$></i></div><br /> </MTEntries> ***[my google ad code goes here]***
So really, if you take out the note at the top and the google ads the meat of all this is:
<MTEntries> <b><$MTEntryDate format="%b %e, %Y"$>: <a href="<$MTEntryPermalink$>"><$MTEntryTitle$></a></b><br /> Comments: <$MTEntryCommentCount$> | <MTEntryIfCategories>Categories: <MTEntryCategories glue=", "> <MTBlogIfArchives archive_type="Category"> <a href="<$MTCategoryArchiveLink$>"><$MTCategoryLabel$></a> <MTElse><$MTCategoryLabel$></MTElse> </MTBlogIfArchives></MTEntryCategories></MTEntryIfCategories> <br /> <div style="padding-left:10px;"><i><$MTEntryExcerpt$></i></div><br /> </MTEntries>
Then I saved and republished, of course, and it seems to work just fine. Obviously if you're going to try this you should back up any template pages you are using now, because I am, on alternate days, an idiot and prone to mistakes.
Tags: category pages in TypePad, TypePad hacks













Thanks for posting this, Debra. If I do upgrade from basic to pro on Typepad, I will find this really helpful. At the moment I can't get into the html though.
And yes, you are a genius!
Posted by: Maxine | June 25, 2006 at 04:57 PM
OH....MY....G...OODNESS! That was easy for you to say, Debra! Of course you're a genius!
Posted by: Susan | June 25, 2006 at 05:07 PM
Aw, shucks, guys....
Posted by: Debra Hamel | June 25, 2006 at 06:16 PM
This looks like just what I've been hoping to do for Parent Hacks! Thank you for this. btw, I found you by clicking over from my referrer log -- you were reading my tutorial about Typepad and Adsense! I have a feeling we have a lot in common.
Posted by: Asha Dornfest | June 26, 2006 at 01:41 AM
Hi, Asha! Yes, I linked to you in a previous post because of your tutorial on putting google ads between posts. It was very helpful. It was also my entree into the TypePad code, which was frightening me a bit. I'd fiddled with html and CSS at Blogger for years, but I was intimidated over here. But now I've got the ads up and I managed to work the category pages. (It's really nuts that the default is to list *all* the posts in a category.) I even made changes so that the text in these input boxes would match the rest of the page (this was bothering me!). I'll check out Parent Hacks more fully.
Posted by: Debra Hamel | June 26, 2006 at 08:58 AM
Debra, great hack, thanks for sharing it! It worked great on my typepad blog. Keep up the good work!
Posted by: Phil Van Treuren | January 22, 2007 at 12:27 PM
Phil, it *does* look great on your blog! I'm glad to have been of help.
And what a strange and interesting blog you have. I like the idea of using blogs to examine such a narrowly defined topic.
Posted by: Debra Hamel | January 22, 2007 at 01:41 PM