You see, under normal circumstances you would need the space to be appended automatically, saving you the trouble of adding this in your theme, each time you call a category listing function. However, there are cases (such as mine) where a space is unnecessary and, if you’re as nit-picky as I am, an eye-sore. There’s a way to fix it, though, so let’s get to it.
The function I use to list my categories is called the_category(). I use it in such a way that quotes (and commas) are wrapped around each category’s name. When there’s only one category, this isn’t a problem, but with multiple categories an extra, unneeded space is inserted. Here’s what my code looks like:
“<?php the_category('”, “') ?>”
As you can see, there are no extra spaces in my code, so the problem is coming from Wordpress itself. The file is located in your wp-includes/template_categories.php file. On line 78, you should find if (0 < $i) $thelist .= $separator . ' ';. Yep, that right there is the problem. Snip it out (so it looks like if (0 < $i) $thelist .= $separator;), and you’re all set.
Hopefully this’ll be useful for someone. It took me awhile to decide to do it, since I figured it’d be a hassle to get into the code, but it wasn’t really that difficult to locate and destroy fix the problem.

I never noticed that here. Mine doesn’t do that. And since you fixed it, well, we can’t see an example :(
Good fix, Jona.
July 15th, 2005 at 12:37 am
Where the categories would be something like: Posted in “Category 1,” ” Category 2″, they now say: Posted in “Category 1,” “Category 2″ — notice the space before Category 2 in the first one.
July 15th, 2005 at 1:02 am
Wow, I would have never noticed that. Ha, good job Jona!
July 15th, 2005 at 7:57 am
I think that the strike tag was decapreated (spelling lol?). You should use the del tag.
/off-topic
July 17th, 2005 at 10:45 am
Thanks, nice catch, Jason.
July 17th, 2005 at 5:33 pm