« return to hot glue media

One Reason A Single Post or Page Might Not Show Up

I just had a wee problem with one of my websites. I was trying to publish a post called “Green”. It put all the information in, and it published just fine, but when I went to look at the single post, I got a 404 error. I wasn’t getting any 404 errors on any other post or page on my site.

I asked the internet what to do about this, and the internet suggested that there might be an issue with my custom permalink structure. (My website was set up to display as http://www.mysite.com/%postname%/.) To diagnose a permalink issue, you go and set your permalinks back to the default. I did that, and my post showed up. So, I reset my custom permalinks to http://www.mysite.com/%category%/%postname%/, and my post went back to 404.

Clearly, there was a permalink problem, but I didn’t know what it was.

The weird thing was, if I manually edited the post slug in the permalink in the post to, say, Green1, it showed up on my site just fine right where it was supposed to.

Then, I realized that I tried to write this post before, but as a page. It was a fail page, though, so I trashed the page. Since WordPress has integrated trashcans in their admin area, that means that the program holds onto deleted content until you empty your trashcan. Turns out, there was a page in the trash also called “Green”, and it was conflicting with my current live page called Green. I deleted the old page permanently, and my post showed up immediately.

The moral of the story is: If you have a mysteriously missing page or post, check the trashcan to make sure you’re not duplicating a title (really, a post/page slug) isn’t conflicting with your new post. Trashed items are apparently not segregated from the rest of your content, and exist in the site’s navigation structure.

The moral of the moral is: take out the damn trash.

made this mess on August 3rd, 2010 and filed it under Random Drips, WordPress

Comments are closed.