NetHere Knowledge Base (KB)
Main ::Web Hosting
Minimize Text   Default    Enlarge Text

Custom Error Pages

Custom Error Pages

 

NetHere can assist you in configuring your own custom error pages for your web site. 

 

For example, when a visitor to your site enters the wrong URL for a page within your site, they are normally directed to a standard NetHere Not Found (404) error page.  You can design your own Not Found page that the visitor would be redirected to instead of the NetHere 404 error page. 

 

Below are the most common errors that you could develop a customer error page for:

400 - Bad request

The request could not be understood by the server due to malformed syntax.
401 Unauthorized

The request requires user authentication.
403 - Forbidden

The server understood the request, but is refusing to fulfill it.
404 - Not Found

The server has not found anything matching the requested URI.

500 - Internal Server Error

The server encountered an unexpected condition which prevented it from fulfilling the request.
501 - Not Implemented

The server does not support the functionality required to fulfill the request.
503 - Service Unavailable

The server is currently unable to handle the request due to a temporary overloading or maintenance of the server.

 

How you configure your site to use a custom error page depends on the platform your site is hosted on, either a Windows 2000 platform or a Unix platform.  If you do not know the platform your site is being hosted on, please contact us at 1-888-638-4373 (1-888-NetHere) or webhosting@nethere.com with you domain name and we can assist you.

 

Windows 2000

 

If you site is being hosted on a Windows 2000 platform, create the HTML page you want to use as your error message and upload it to your web directory.

 

Once uploaded send an email to webhosting@nethere.com or contact us at 1-888-638-4373 and let us know the following:

 

  1. The domain name.
  2. The error that you would like the page applied to.
  3. The location and name of the corresponding HTML page.

 

For example:

 

  1. mydomain.com
  2. 404 error
  3. mydomain.com/error/404.html

 

This tells us to configure the 404 error for your site to point to the 404.html page that you developed and uploaded to your error subdirectory.  With Windows 2000, we must configure your site to use the custom error page that you have created.

 

If you have any questions, please let us know and we can assist you.

 

UNIX

 

If you are hosted on a Unix platform, you will need to use .htaccess in order to configure custom error pages for your site.  NetHere does not allow .htaccess for sites by default so the first thing you will need to do is to contact us so that we can configure your site so that you may use .htaccess. 

 

Simply send us an email at webhosting@nethere.com or contact us at 1-888-638-4373 and request us to allow .htaccess for your site so that you can create custom error pages and we will configure it for your site.

 

Next, you will need to create a .htaccess file.  To create a .htaccess file, you simply type the appropriate text into any text editor like Notepad or Text Pad.  Once you have entered the text, you simply save the file as .htaccess.  The file actually has no name but an 8 letter file extension.  Because .htaccess is a nonstandard file, it may not be accepted on certain systems.   With most operating systems, all you need to do is to save the file by entering the name as ".htaccess", including the quotes.  If this doesn't work, you will need to name it something else (for example, htaccess.txt) and then upload it to our server.  Once uploaded, you can then rename it using an FTP program to .htaccess.

 

When you have created your .htaccess file, you will need to upload it to the sites root directory, not a subdirectory within your site.

 

Below are three examples of text you type into your .htaccess file in order to configure your site to use a custom error page that you have created. 

 

Example:

 

ErrorDocument 401 http://mydomain.com/error/401.html
ErrorDocument 403 /error/403.html
ErrorDocument 404 http://www.mydomain.com/error/404.html

 

In this example, you have created a series of custom error pages, 401.html, 403.html and 404.html and uploaded them to the error subdirectory of your site.  You may use either the relative path to the page (/error/403.html) or absolute path (http://mydomain.com/error/401.html, http://www.mydomain.com/404.html) to direct the error to the appropriate page.

 

As always, please let us know if you have any questions or if we can be of any assistance.





 



 

Search Glossary Saved Article Contact us