Project

General

Profile

« Previous | Next » 

Revision 8407

web/**/.htaccess: RewriteOptions: Redirect dir paths without the trailing / to the datasource's homepage, and let dir paths with the trailing / point to the directory index. This is the opposite of the way it was before, and is more intuitive because the trailing / indicates a directory listing, while the trailing / would generally be omitted when linking to the datasource itself.

View differences:

.htaccess
10 10
# don't rewrite existing paths
11 11
RewriteCond %{REQUEST_FILENAME} -d [ornext]
12 12
RewriteCond %{REQUEST_FILENAME} -f
13
RewriteRule ^.+$ - [discardpath,noescape,last]
13
RewriteRule ^(?!/).+$ - [discardpath,noescape,last]
14 14

  
15 15
# handle DirectoryIndex subrequests
16 16
RewriteRule ^index$() $1 [discardpath,noescape]
17 17

  
18
RewriteRule ^.*$ ../_src/ctfs-comments_worksheet.xls#$0 [discardpath,noescape,last,redirect]
18
# dir without trailing / is provided as an absolute filesystem path
19
RewriteCond $0 ^/ [ornext]
20
RewriteCond #$0 ^(.*)$
21
RewriteRule ^.+$ ../_src/ctfs-comments_worksheet.xls%1 [discardpath,noescape,last,redirect]

Also available in: Unified diff