Wordpress tips and tricks - custom 404 (error) pages

If you're new here, you may want to subscribe to my RSS feed. One advantage of subscribing to RSS feeds is that you don't have to constantly re-visit this site to check for updates within specific sections you might be interested in because your browser or Feed reader will do this for you automatically on a regular basis plus you can even get email notification. Thanks for visiting!

[View FULL Article] One of the more underused features in wordpress themes is the ability to create and modify the 404 page - so to try to rectify this I thought I’d run through what I do with 404 pages on Binary Moon (and my other Wordpress site). I use this simple technique to try to make errors a bit more and helpful for people who have ended up at the wrong place. I’m hoping that not too many people see the 404 page but just in case here is what I’ve done.
Basically I duplicate a normal page template and name it "404.php". I then remove "the loop" and add some some static code which explains that there has been an error and a few possible solutions (archives, search).
Finally I use query_posts to add in a new loop which displays links to the 5 most recent articles. Below is the actual code I use on this site for my 404 page (you can see it in action here - http://www.binarymoon.co.uk/9837489)

Article copyright BookOfTips.Blogspot.Com - Find helpful tips that can help you with your daily activities. All rights reserved. No part of an article may be reproduced without the prior permission.

Wordpress tips and tricks - custom 404 (error) pages - Related Tips / Tricks / Hacks

If you enjoyed this post Subscribe to our feed

No Comment

Post a Comment