404 Error Pages
Error pages play a crucial role in providing a user-friendly experience when visitors encounter issues such as missing files or restricted access. You can customize these pages to guide users when they face the following errors:
- 401 Unauthorized: The visitor does not have permission to view the file or directory.
- 403 Forbidden: Access to the file or directory is not allowed.
- 404 Not Found: The file or directory is not found.
- 500 Internal Server Error: An error occurred on the server.
Accessing Error Pages
To modify error pages, follow these steps:
-
Log in to your control panel.
-
From the main control panel menu, click on the "Error Pages" icon.
You will see a screen displaying a list of error types such as
401.shtml
,403.shtml
, etc. By default, these files will not exist. The "View" link next to each error type allows you to see the default message that visitors encounter when they encounter that particular error.
Changing the Error Pages
There are two methods to change the content of error pages:
Method 1: Editing Directly in the Control Panel
- From the Error Page menu, click on the file name of the error page you wish to edit (for example,
404.shtml
). - A text box will appear where you can paste your HTML code.
- After editing, save the changes. This allows you to quickly customize the error page content without needing to create the file manually.
Method 2: Uploading Custom Error Pages
- Create the error page files (e.g.,
404.shtml
,401.shtml
, etc.) yourself using any HTML editor. - Upload the files to your public_html directory.
- Ensure that the file extensions are
.shtml
for the error pages to function correctly.
For more help on method 2, refer to this article
Conclusion
Customizing error pages helps improve the user experience by providing friendly, branded messages and guidance, rather than showing generic error notifications. By using the above methods, you can easily update error pages to align with your website's design and provide helpful navigation for visitors encountering issues.