Weve all seen them, youve been browsing a web site and you click a link and nothing loads apart from the words 404 Error along with the usual stuff.
So what is a 404 Error page? The 404 Error page, basically informs the user that the server cannot find the file they are looking for. However, instead of using the default 404 Error page you can create your own, this is how you do it.
First, you positive need
your .htaccess file which should be within your website directory. If you cannot find it you will need to create one. You will have to contact your host asking them how you would go about making or editing this file. They can want you to make use of
a text editor and then upload it, or they may want you to use a PICO editor and create or edit the document
on the server.
How you have access to the .htaccess file lets edit it. Add this line to the .htaccess document
:
ErrorDocument 404 http://www.yourdomain.com/404page.html
Make sure this line is kept on online. This is where your 404 Error page is kept.
Now youve change the .htaccess file you absolutely need to create the page. This is simply a normal HTML document. Once youve created the HTML document, save it and call it 404page.html. Now the next step is to upload the .htaccess file and the page to the server.
Now that is done your next step is to turn it on. This is done by setting the CHMOD attribute to 644. You might
do this via telnet or some FTP programs. If your going to telnet into your server, use the following command:
chmod 644 .htaccess
Now test to see if its worked. Just go to a page that doesnt exist on your server and you should see your new 404 Error page. If not, then generate sure the CHMOD is set correctly, and if that doesnt help, you may want to inquire of
your hosting company for support.
I currently own and run a small E-commerce template web page
located at http://www.sjh-designs.co.uk. You may find several more guides located at http://www.sjh-designs.co.uk/guides.htm.