msgbartop
Just another WordPress site
msgbarbottom

07 Jul 09 Changing Your Tag’s Case In WordPress

Yet another pet hate of mine is things capitalised incorrectly. For me things like tags need to be either first letter uppercased of lowercases, and definitely not a mix of both. The problem with WordPress is that you unfortunately cannot change the case of a tag once it’s been used. This is because all your tags are put into a table the first time you use them, and from then on no matter what case you type a tag in, it will default to the capitalisation that is used in this table. The offending table is the wp-terms table.

This table contains a list of names and slugs (url friendly names) for all your tags. If you want to change the case of one of your tags you will need to do it here, either via console or phpMyAdmin or something else. Myself I went and just set all the names equal to the slug, and then changed the one or two tags I had with spaces in them back to something more rational. Whether you want to do it the same way as myself or not is up to you. Though if you want to you will merely need to run and update something like: UPDATE wp-terms set `name` = `slug`.

07 Jul 09 Changing WordPress Default Theme Front Page To Show Post Excerpts Only

This is one of those things that tends to get under my skin. Web sites with long pages showing far too much information on the front page. Realistically I think the best approach is to give users access to plenty of information, but not necessarily having them bombarded with it. For the WordPress Default theme (the one based on Kubrick) this is done by showing only post excerpts as opposed to the entire thing.. You can follow the steps below to this affect:

  1. Open up the index.php page of the theme. You can do this one of two ways.
    1. Manually: locate the folder wp-content/themes/default and open the index.php file
    2. WordPress Admin: look under the Appearance menu and select Themes. Once here select the Main Index Template page from the list on the right hand side of the editor.
  2. On the 20th line (or thereabouts) you will find the text: < ?php the_content(‘Read the rest of this entry »’); ?>
  3. Replace this text with the text <?php the_excerpt(); ?>

That’s it. One note though, I would always comment out any changes I have made so that should something go wrong I can always switch back. If you want to comment it out instead of replacing it then you would use < ?php //the_content(‘Read the rest of this entry »’); ?>