Tag Archives: Wordpress Tag Page

WordPress 2.5 Upgrade

I just ran the my first set of WordPress 2.5 upgrades.

The first upgrade was to a very small blog with only 2 plugins, the second was to a larger blog that had several plugins installed. Both upgrades went smooth as silk.

The WordPress 2.5 dashboard and layout are totally different from anything WordPress has released before and it will take some getting used to. I did use the upgrade automatically option on a couple of the plugins and everything worked as expected.

One new feature I really like is the Tag management. As an example I had a tag that should have had a word capitalized that was not. I was able to modify the tag display with a couple clicks and then verify that it was corrected in my tag cloud.

So far WordPress 2.5 looks great and I will follow up with more data as I upgrade the rest of my blogs.

WordPress Tag Template

Using a tag page for marketing is something that can really help your ROI by using the WordPress Tag Template and creating a very specific page design for any tag.

Based on the WordPress Template Hierarchy it is very easy to create an individual page for a tag. If you look at a Tag Cloud on a site you will notice that there are always tags that get mentioned more than others. These tags should represent the most popular topics for a site and taking advantage of the WordPress Tag Template can result in a focused marketing campaign for these given tags.

The WordPress Tag Template flows like this :

  1. tag-slug.php
  2. tag.php
  3. archive.php
  4. index.php

The first template is the key here. If you have a tag you would like to create a custom page for you can copy your tag.php to a new file named tag-slug.php and then modify that page to fit that tag.

Here is an example:

On MusicRamble.com we focus on Classic Rock music. The general tag page lists excerpts from articles for the given tag. Examples of the basic tag pages are George Harrison and Steve Winwood. If you compare those two pages you will notice they are basically the same design.

Now look at Eric Clapton. Notice the sidebars, they have been customized specifically for Eric Clapton. The left sidebar is loaded with products related specifically to Clapton. This has resulted in an increase of Amazon sales for Eric Clapton.

Here is how it was accomplished.

  1. Copied the tag.php to tag-eric-clapton.php
  2. Removed the call to the sidebars, get_sidebar()
  3. Copied the contents of the sidebar.php file
  4. Placed the copied code where the previous call to get_sidebars() was.
  5. Moved all items in left sidebar to right sidebar
  6. Placed the product links in the left sidebar.

The resulting custom tag page shows up in the file list on the WordPress -> Presentation -> Theme Editor menu so it is easy to work on. At any point if we decided not to use this page, all we have to do is delete it and the default tag.php will once again be used for this tag.

Are you getting the most out the WordPress Tag Template?

Alternate Background Color of Blog Posts

As my tag pages grow I have been contemplating how I wanted to handle their appearance. The goal is to have as many post excerpts as possible on each tag page while creating a page that is easy to read. I decided to try something a little different that I have not seen on too many blogs, actually, I am not sure I have seen it at all except on some comments, which is alternating the background color of each post.

So, how hard would this be?

It took about an hour to get it the way I wanted it. I am alternating the background color and the Adsense ads on each tag page. A good example is the Google Tag Page since it has a lot of posts.

Rotate Background

Here is a summary of how I did this:

Create a loop counter. Right before the Loop begins set a variable to zero.

<?php
$x=0;
if (have_posts()) : ?>

At this point I would want the Background Color to change, insert code to test for an even number post, and if this is true, add an inline CSS style for the background that would override the stylesheet.

<?php if ($odd = $x%2){?>
<div style=”background-color:#404040;padding:10px 0px 10px 10px;”>
<?php }?>

Then, where the background color should return to the original state, run the same test for the even numbered post and close the div tag set by the Inline Style.

<?php if( $odd = $x%2 ){?>
</div>
<?php }?>

The final step is to add 1 to the counter for each post, which is done at the end of the loop.

<?php
$x++;
endwhile; ?>

Not sure if anyone else likes this style, but it sure seems to make the excerpts easier to read for me. Please let me know what you think ?