Ok, I have a problem, my .htaccess code is:
RewriteEngine on
ErrorDocument 404 /notfound.html
and I have not found.html near .htaccess.
Why is it not working? I don’t believe what I’m seeing. I took the tutorial from here
http://www.htaccessbasics.com/404-custom-error-page/
I just want that every time I access http://www.site.com/ajfasoijfiajsfijaofij to show what is it in notfound.html.
when using
ErrorDocument, the file you’re specifying is relative to DOCUMENT ROOT not.htaccesslocation!Edit:
assume you have
notfound.htmland you want to use it for folderdir01, you create anhtaccessfile inside this folder and add this:If you want to access your file(
notfound.html) in browser it would behttp://www.example.com/dir01/notfound.html. that’s all I could explain!