Web Development Network  |  Sites:    Capital Tutorials    Internet Marketing Books    Arcade Games
Depiction- Webmaster Resources
Stock Image

Contributors: SSD VPS in Europe  |  SEO Las Vegas |  EsqRank |  Free SEO Report

Dental SEO Marketing  |  Best Las Vegas SEO Company  |  Currency Converter Live

Misc Links: Submit Tutorials (Earn $$) l Advertising l Privacy Policy | Site Map

Tutorials > .htaccess > Error Pages


Learn how to create custom 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.



Templora Photoshop Tutorials
Tutorial Man Wallpaper Stock  More