My website URL is: https://gianmarco.ga
I’ve edited my .htaccess file in htdocs to match the ErrorDocuments to a set of custom error pages of my own, but it doesn’t seem to work. When in ErrorDocument 404 I write /errors/404.html or /htdocs/errors/404.html it gives me the standard 404 page and says that the ErrorDocument returned a 404 too. When I write instead errors/404.html or htdocs/errors/404.html it just prints out the line I wrote. When I put an URL like https://gianmarco.ga/errors/404.html it returns me to an actual 404 page from iFastNet instead of the one specified. How do I fix this?
try removing the 404 redirect code from .htaccess and then go to vistaPanel, search or look for error pages option click on it , and then put in the specific error page links in the respective error page textfield.
The right way to define a custom error page is to use /path/to/file.html
. That’s with a slash at the start. You can use a full URL as well, but that causes a second hit to your website, so it should only be used to redirect to an external page.
So why doesn’t your error page work? That’s because Apache does something weird with the /errors/
folder. I don’t know what exactly or why it happens, but I’ve seen it happens on very simple Apache setups as well. Simply renaming your errors
directory to something else (e.g. error
or error-pages
) should fix this.
This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.