Hube02
asked on
Apache Mod_Rewrite folder if index file does not exist
Is there a way to use Mod_Rewrite to redirect if the requested page is a folder and an index page does not exist in that folder?
For example:
Someone types "http://some.site.com/folder/"
If a file that is not considered an index is not located in this folder, then redirect to whatever page. It would likely need to check for any of the following: index.htm, index.html, index.asp, index.php, as well as maybe things like default.html or home.html.
Alternately, can Mod_Rewrite actually check to see that the default pages on the server are and then check for the existence of pages in that list?
For example:
Someone types "http://some.site.com/folder/"
If a file that is not considered an index is not located in this folder, then redirect to whatever page. It would likely need to check for any of the following: index.htm, index.html, index.asp, index.php, as well as maybe things like default.html or home.html.
Alternately, can Mod_Rewrite actually check to see that the default pages on the server are and then check for the existence of pages in that list?
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER