Error Pages

Image from Hosting Services: Error Pages

The standard error pages can be very annoying. When you move a page in your site, visitors have no way of finding where you moved it to in the error page. With custom error pages you can get cool error pages that have the same layout as your site and get rid of the standard ones and replace them with one that will help redirect users to anypage you wish.

There are 5 kinds of errors that can occur, here is the list with the definition:
400 - Bad request 401 -Authorization Required 403 - Forbidden 404 -Wrong page 500 - Internal Server Error

First of all, you will need to create your errors pages. Put anything in them you would like, it doesn't matter. However I would suggest placing a link to your main page on it. Then upload your pages to your site in a sepertate folder and call it anything you'd like.

Now in your .htaccess file, (Please see the .htaccess tutorial to make one if you don't already have one.) copy the following as shown below. Don't wrap the text. You will need to change the folder name in the links to the one you used.

ErrorDocument 400 http://www.yourdomain.com/errordocs/400.html
ErrorDocument 401 http://www.yourdomain.com/errordocs/401.html
ErrorDocument 403 http://www.yourdomain.com/errordocs/403.html
ErrorDocument 404 http://www.yourdomain.com/errordocs/404.html
ErrorDocument 500 http://www.yourdomain.com/errordocs/500.html

Save your .htaccess file and upload it to your server in the main directory. Test it out to make sure it works.

Everything should work, if not, your server may not support this.


Related Articles

  • How To Get Profits From Your '404 Page Not Found' File?
    Page Not Found on this Server. Check the URL and try again. Or Refresh the page...
    This is the annoying error that we will come across every time we surf the web pages. Internet will be changing every minute and day. The web sites that were here are not found next day...
  • Finding The Errors On Your Site
    When you are building your site, and try to test it in a browser, do you sometimes (or perhaps more often) get an error message telling you that your site contains a script error, and would you like to continue running scripts on the page - yes or no? If so, look at that screen before discounting...
  • PHP Debugging
    A few tips for debugging your PHP
  • 404 Error Pages and Search Engine Optimization
    We have all run into the famous 404 page not found errors pages before when surfing the web. In the past they have always been considered to be somewhat of a nuisance. Find out here how you can take this negative and turn it into a positive....
  • Increase Your Traffic By Recovering Your Lost Visitors
    If you spend any time surfing the Internet, youve probably encountered a few error messages. Error messages have numerous causes, such as misspellings, outdated links or internal server errors. When an error is encountered, your server will display specific generic error pages according to the....
  • Alternating Backgrounds
    Alternate the backgrounds of table rows displayed from a MySQL database.
  • The Secret Of Custom Error Pages
    Just about every website has a broken link here or there that no longer connects to the page specified in the URL. These broken links loose you visitors and cost you money. Often what happens is you delete or move a page, and then forget to update some of the other pages on your site that lin...
  • Keeping Visitors Through 404 Errors
    Avoid ugly error 404 pages that turn visitors away. Give them the option to stay on your site by giving them a custom error 404 page that looks and feels like your site. Having a broken or old link gives a very bad impression and can lose you a customer before you have had a chance to impress them ...
  • Counter in ASP
    A hit counter is an essential part of a site to know how many people are coming to site. Here is an easy way to make a counter. All you need is access to ASP and be able to give a write access to a directory...
  • Quick And Easy Custom 404 Pages
    By design, the server that hosts your web site delivers a 404 Error / Page Not Found when a surfer clicks on a link that the server cannot find or something else unexpected happens. The most common error page is the HTTP 404 Not found: The requested URL/whatever.html was not found on this server......

Contact Web Design Outsource and get started today

Need Website Designing, Development, Redesigning, Maintenance and SEO services or help growing your company's web presence? Request a free Quote Now.