Home arrow Apache arrow Implementing Sensible 404 Pages With Apache
APACHE

Implementing Sensible 404 Pages With Apache


'HTTP 404 Not Found' reads the title. It's not pretty. As web surfers, we have all collided with 404 error pages, and some endeavour to correct the error be checking the URL for stupid mistakes that often happen. In this article Steve talks about handling 404 errors with Apache, and also suggests ways to keep visitors on your site by making the content of your 404 page informative and useful.

Author Info:
By: Steve Adcock
Rating: 3 stars3 stars3 stars3 stars3 stars / 10
May 01, 2002
TABLE OF CONTENTS:
  1. · Implementing Sensible 404 Pages With Apache
  2. · Custom error documents
  3. · Designing the error document
  4. · Conclusion

print this article
SEARCH DEVARTICLES

Implementing Sensible 404 Pages With Apache
(Page 1 of 4 )

'HTTP 404 Not Found' reads the title.
'The page cannot be found' reads the heading on the page.

It's not pretty, or even clever. As web surfers, we have all collided with 404 error pages, and some endeavour to correct the error be checking the URL for stupid mistakes that often happen. If we find we have not mistyped the URL, we probably close our browser or fly off to another site, never to return again. As Edgar Allan Poe wrote, "Nevermore!" This is a major problem for fellow webmasters.

The thing about default 404 error pages is they often give only the error code and a short description, and if you were oblivious to the web site you were attempting to visit, the page reveals very little about the site, or a link to the home page so you can start again. Many webmasters circumvent this issue with what’s known as custom error pages. These are pages that the Webmaster creates to his or her liking, with the company logo intact and any dialog or links deemed appropriate. Other common error documents include 500 Internal Server Error, 403 Forbidden and 401 Authorization required.

This article refers to the most often-hit error document on the Internet, the infamous 404 Page Not Found error. This error occurs when a user requests a page from a web server that does not physically exist (the page, that is). The most common culprit is a misspelled page extension or link, along with deleting a page from the server without updating any corresponding links to that page. Although many sites now rely on dynamic database content to generate their pages, these sites too still have room for 404 errors to occur without the webmaster even knowing it.

Let us take a look at creating an effective 404 Page Not Found error document, how to keep more of our visitors happy, and, most importantly, coming back to our site.
blog comments powered by Disqus
APACHE ARTICLES

- Programmatically Manipulating Microsoft Exce...
- Installing PHP under Windows
- Compressing Web Content with mod_gzip and mo...
- Compressing Web Output Using mod_deflate and...
- Setting Up Apache 2.0.45 to Parse PHP Pages
- Custom Error 404 Documents with PHP
- Using Apache and PHP on Mac OS X
- ASP: Active Sessions, Active Logins and Tota...
- Working With Oracle on Windows: Part 1
- The Quick-n-Dirty Guide to Setting Up Apache...
- Installing Apache With SSL: The Complete Gui...
- 7 Powerful .htaccess Customization Tips
- Trap And Get Notified: A Practical Solution ...
- One Way To Use Server Side Includes
- Using ForceType For Nicer Page URLs

Watch our Tech Videos 
Dev Articles Forums 
 RSS  Articles
 RSS  Forums
 RSS  All Feeds
Write For Us 
Weekly Newsletter
 
Developer Updates  
Free Website Content 
Contact Us 
Site Map 
Privacy Policy 
Support 

Developer Shed Affiliates

 




© 2003-2017 by Developer Shed. All rights reserved. DS Cluster - Follow our Sitemap
Popular Web Development Topics
All Web Development Tutorials