404 error webpage, how to create a custom 404 error web page, guide, tips
Home About Us Reference Product Service Sitemap

How to create a custom 404 error web page

It is important to set up and create a custom error web page to handle 403 error, 404 error, 500 error, or other errors from your web server. If you do not set it up, you will lose your traffic because your web hosting server may direct your traffic to their pages, mostly their ad pages or you may have some webpage plug-in to direct to their pages. The following are the steps to do it:

1. Make sure that your web hosting server has .htaccess enabled.

2. Create a .htaccess file and enter the following text:

ErrorDocument 404 /404.html
or you could use a full url

ErrorDocument 404 http://www.edusoftmax.com/404.html
You can also do like this:

ErrorDocument 403 /403.html
ErrorDocument 404 /404.html
ErrorDocument 500 /500.html
Note: To create .htaccess file, first you need to open notepad, and then choose Save As ".htaccess". double quotes should be around ".htaccess".

3. Create a 404.html. If you want to redirect to your home page, you can use the following code:

<meta http-equiv="Refresh" content="5; URL=www.edusoftmax.com">
4. Upload .htaccess and 404.html to the root of your web server.

The following is http error codes and explanation:

Code No.      Explanation
  100 	Continue 
  101 	Switching Protocols 
  200 	OK 
  201 	Created 
  202 	Accepted 
  203 	Non-Authoritative Information 
  204 	No Content 
  205 	Reset Content 
  206 	Partial Content 
  300 	Multiple Choices 
  301 	Moved Permanently 
  302 	Moved Temporarily 
  303 	See Other 
  304 	Not Modified 
  305 	Use Proxy 
  400 	Bad Request 
  401 	Unauthorized (directory is password-protected) 
  402 	Payment Required 
  403 	forbidden 
  404 	file not found 
  405 	Method Not Allowed 
  406 	Not Acceptable 
  407 	Proxy Authentication Required 
  408 	Request Time-Out 
  409 	Conflict 
  410 	Gone 
  411 	Length Required 
  412 	Precondition Failed 
  413 	Request Entity Too Large 
  414 	Request-URI Too Large 
  415 	Unsupported Media Type 
  500 	Internal server error (cgi script error) 
  501 	Not Implemented 
  502 	Bad Gateway 
  503 	Service Unavailable 
  504 	Gateway Time-Out 
  505 	HTTP Version Not Supported
©1994 - 2010 Edusoftmax Inc. All rights reserved. Questions? Comments?    Visitors: