Website | Windows Tips | SEO

Monday, September 26, 2005

Listing Blogger Archives by Title

I know I put these instructions somewhere, but now I need them again and I can’t find them as usual.

I hunted down the page again that has the instructions:

http://help.blogger.com/bin/answer.py?answer=892

The fast answer is that you copy the part of your template between <Blogger>...</Blogger>

And paste it here:

<MainPage> <Blogger>...</Blogger> </MainPage> <ItemPage> <Blogger>...</Blogger> </ItemPage>

The same code is in there twice, once for the main page and once for the item page.

<ArchivePage> <Blogger> <BlogItemTitle> <a href="<$BlogItemPermalinkURL$>"><$BlogItemTitle$></a> <br /> </BlogItemTitle> </Blogger> </ArchivePage>

I really hate this….

The main pages work, but the Item pages just show the tags…. Just like the last two times I have done this.  I have the instructions on how to fix this some where but I can’t find them.

So it looks like I have to figure this out all over again…. For the third time.

Hopefully I will be a little faster at it that the first two times.

In the <MainPage> you can cut out all the tags that are marked <ItemPage> because I don’t think they do anything…  But that won’t solve the problem.

I searched some more and found some note on the last time I did this procedure, and how I solved the problem is I cut out everything between the <ItemPage> and </ItemPage> tags, then I started adding the code back in a few lines at a time.

This time I did the same thing and I found out that if you have two nested  <ItemPage> tags then your blog will not work.

It will kick out of the blogger mode retroactively to the first tag – don’t ask me why or how….  That’s just what it does.

So you need to go through and delete any extra <ItemPage> tags you have.

To try and make this a little more clear:

You can do this:

<ItemPage>
</ItemPage>
<ItemPage>
</ItemPage>

And you will have no problems.

However, if you do this:

<ItemPage>
<ItemPage>
</ItemPage>
</ItemPage>

Blogger will start at the first <ItemPage> tag and refuse to go into Blogger mode so your <blogger> tags are useless.

Also on the archive page the title does not link back to the home page, only the item pages do.

Right after the <body> tag you will find something like this

<h1 id="blog-title">
   <ItemPage><a href="<$BlogURL$>"></ItemPage>
     <$BlogTitle$>
     <ItemPage></a></ItemPage>
  </h1>

Change it to this:

<h1 id="blog-title">
   <ItemPage><a href="<$BlogURL$>"></ItemPage>
<ArchivePage><a href="<$BlogURL$>"></ArchivePage>

     <$BlogTitle$>
     <ItemPage></a></ItemPage>
           < ArchivePage ></a></ ArchivePage >
  </h1>


I also like to add the archives links on to the item pages

To do this just delete the <MainOrArchivePage> tags around the archive section

These are located toward the bottom.