Bluehost.com Web Hosting $6.95

mod_rewrite question with directory indexing

This is a discussion on mod_rewrite question with directory indexing within the Linux Web Servers forums, part of the Web Server and Related Forums category; I have a script that I use as a template for all the files I serve up. I used mod_rewrite ...


Go Back   Usenet Forums > Web Server and Related Forums > Linux Web Servers

FAQ Members List Calendar Search Today's Posts Mark Forums Read
  #1 (permalink)  
Old 08-07-2003
q777
 
Posts: n/a
Default mod_rewrite question with directory indexing

I have a script that I use as a template for all the files I serve up.
I used mod_rewrite to apply this script to all html files that are
requested. However, I'm running into one issues - with directory
indexing. I have my server setup to look for index.html as the
directory index. If you go to http://server.com/directory/ it looks
for http://server.com/directory/index.html. The problem is, the
rewrite rule for the template script always gets run. I only want it
to apply if there exists a file. So if http://server.com/directory has
no index.html, I want it to just list the directory contents, not run
the template script. I've played with RewriteCond with the -f and -d
switches to test for existence of the index.html file but that doesn't
seem to quite work. Anyone have a similar setup/solution? Thanks

Q
 
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are Off
[IMG] code is Off
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On




All times are GMT +1. The time now is 12:57 AM.


Powered by vBulletin® Version 3.7.3
Copyright ©2000 - 2009, Jelsoft Enterprises Ltd.
Content Relevant URLs by vBSEO 3.0.0