Website Upgrade

Maybe it was the trip to Chicago. Maybe it was learning that there is an iPhone app for Wordpress. Either way I decided to redesign the site again. I really wasn’t unhappy with the previous design, but have grown tired of the somewhat dated backend CMS. More on that later, maybe.

Installing WordPress was a breeze. The five-minute install worked perfectly. Of course, I first installed it on my local environment to start developing a new design and template, and to test importing content from TextPattern, the CMS that I’ve used routinely over the last two years. As it turns out, moving my existing content from TextPattern to Wordpress had it’s snags, but I found some great advice, along with a better TextPattern to WordPress import script from Alex Brie.

The next challenge I faced was the way WordPress handles permalinks and category links. In short, even after following all of WPs standard advice for creating ‘pretty permalinks’, I was still left with category links that look like:


www.site.com/category/category-name/post-name/

when what I really want is


www.site.com/category-name/post-name/

The later pattern has benefits for the end user (URL recognition) and search optimization (URL keyword density). In this context, Wps literal use of /category is completely superfluous, and for me has no place in a meaningful URL pattern.

After a little research, it seems that WordPress rewrites the URL this way in order to provide total compatibility with WordPress pages, the URLs of which follow the pattern: www.site.com/page-name. This allows WP pages to have any name and never conflict with the URL of a category. Put another way, adding /category creates an absolutely unique namespace for categories.

I suspect however that many WordPress users employ WordPress pages for only a handful of common ancillary items—about, contact, etc—while using categories to manage the bulk of their content. For these users the potential for confusion and URI collision is very low: it’s an easy and obvious choice to simply eliminate /category and then to avoid creating a category with the same name as a page, i.e., don’t create a category named ‘about’ or ‘contact’.

The WordPress forum is littered with various workarounds, plugins, and hacks, but none are without negative side effects. I’m certainly not above hacking source code, but doing so now can come back to bite you when you upgrade your WordPress installation later. Besides, shouldn’t there be a way to manage it in WordPress’ permalink settings? Or if not there, then perhaps in the .htaccess mod_rewrite rules? Apparently not…at least not yet. There is an “Idea forum” thread dedicated to removal of the wp category base, and I will be following this closely.

Bookmark and Share

Leave a Reply