I have a url like:
http://skepticalgamer.com/category/slam-the-controller
I’d like to strip out “category” from the URL. So I’d want:
http://skepticalgamer.com/slam-the-controller
to act as if it were the original URL above. Is that something that can be done with mod_rewrite?
Yes, you could do this with mod_rewrite by doing something like this:
This will take the URL:
and rewrite it to:
http://skepticalgamer.com/category/slam-the-controller
Removing the category base is easily done with WordPress Plugins » WP No Category Base, making changes in .htaccess unnecessary. The plugin doesn’t permanently change URLs in the database, so if you disable the plugin, you get your category base back with no 404s for posts.