HTMLCOOK -
Main Page
- lists all articles and tutorials
Google
  Web www.htmlcook.com
1&1 hosting - UK hosting - Buy your domain from 1&1 - Best domain prices in the UK!
1&! US hosting - Hosting Made Easy. Order 1&1 Microsoft Web Hosting from the World’s # 1 Web Host. Get up to 5 FREE domains! Linux hosting, dedicated servers. Amazing service.


The 404 Error and how to turn it to your advantage

If you have your own domain name then you should be able to control your own 404 error page.

Its a simple thing to do, and will help keep any lost traffic on your site.

To create a 404 error page, just make a normal page but save it was 404error.htm

Refresh and Back?

If you want to include refresh then you need this code
javascript:location.reload()
If you want to include back then you need this code
javascript:history.back(1)

Then you need to create a text file with the following line in it

ErrorDocument 404 http://www.yourdomain.com/404error.htm

and save it as ".htaccess" and put it in the root directory for your site.

Now your custom 404 error page should work. Try it by typing in a url you know doesn't exist.

By adding other links to the custom 404 page you give your readers a chance to return to where they want to. If you just have the refresh and back options, or main page, then you're not giving them much choice. Mogga had a couple of subdirectorys - which people might want to get back to. They're not linked from the main page, so links on the 404 page enable people to get back to them.

All information copyright 2001 Freebies Network UK LTD
HTMLCOOK is a subsidary of mogga.com