| How do I customize error messages?
You can now use cPanel or X-Controller to add custom
error messages.
Manual Method:
First, you need to download this .htaccess file, unzip it. Next, open the file .htaccess using notepad and change your_domain.com to the domain name you want to upload this .htaccess file to.
Note for the file named after your_domain.com, you may want to change these names or you can just leave them as is and create your .html pages corresponding to these names.
The .htaccess file should look like this:
ErrorDocument 400 http://www.your_domain.com/400.html
ErrorDocument 401 http://www.your_domain.com/401.html
ErrorDocument 403 http://www.your_domain.com/403.html
ErrorDocument 404 http://www.your_domain.com/404.html
ErrorDocument 500 http://www.your_domain.com/500.html
ErrorDocument 501 http://www.your_domain.com/501.html
ErrorDocument 502 http://www.your_domain.com/502.html
ErrorDocument 503 http://www.your_domain.com/530.html
What you have to change in order for your errors pages to work is in red. What you may want to change is in blue and you need to create these using your favorite html editor.
Here is an example:
Let's say we want to point our visitors to a file not found page when they access a link that does not exist within our web site. We create a file named 404.html with the following content:
Not Found
The requested object does not exist on this server. Please double check the URL you requested to make sure it is correct. Otherwise, please use the following links to find what you are looking for: ... and so on.
Upload this 404.html file to your -www directory and try to access www.yourname.com/afileyoudonthave.html, you should see the error page above.
---------------------------------------------------------------------------
Error number meaning:
400 Bad syntax
401 Unauthorized Access
403 Forbidden
404 File Not Found
500 Internal Server Error
501 Not Implemented
502 Overloaded
503 Gateway Timeout
Ps: the most common errors are in red. If you do not want to creat the files other than the red part, do not include them in your .htaccess file. It should look like this:
ErrorDocument 401 http://www.your_domain.com/401.html
ErrorDocument 403 http://www.your_domain.com/403.html
ErrorDocument 404 http://www.your_domain.com/404.html
ErrorDocument 500 http://www.your_domain.com/500.html
|