From 1e0215d7eb8a1f334365f78beee52b99ef4c74d9 Mon Sep 17 00:00:00 2001
From: garvinhicking <garvinhicking>
Date: Mon, 18 Apr 2005 16:45:24 +0000
Subject: [PATCH] patch up rewrite rule so that index.php may not get rewritten
 to index.php?url=index.html, as it only wastes cycles. (Even though it didn't
 happen on my install...anyways, the rewrite rule also only steps into effect
 if $serendipity['indexFile'] != 'index.php', we may want to create a
 conditional rule here.

---
 include/tpl/htaccess_cgi_rewrite.tpl | 2 +-
 include/tpl/htaccess_rewrite.tpl     | 2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/include/tpl/htaccess_cgi_rewrite.tpl b/include/tpl/htaccess_cgi_rewrite.tpl
index b9c4429..860c2f0 100644
--- a/include/tpl/htaccess_cgi_rewrite.tpl
+++ b/include/tpl/htaccess_cgi_rewrite.tpl
@@ -18,7 +18,7 @@ RewriteRule ^{PAT_PLUGIN} {indexFile}?url=plugin/$1 [L,QSA]
 RewriteRule ^{PAT_SEARCH} {indexFile}?url=/{PATH_SEARCH}/$1 [L,QSA]
 RewriteRule ^{PAT_CSS} {indexFile}?url=/$1 [L,QSA]
 RewriteRule ^{PAT_AUTHORS} {indexFile}?url=/{PATH_AUTHORS}/$1 [L,QSA]
-RewriteRule ^index\.(html?|php.?) {indexFile}?url=index.html [L,QSA]
+RewriteRule ^index\.(html?|php.+) {indexFile}?url=index.html [L,QSA]
 RewriteRule ^htmlarea/(.*) htmlarea/$1 [L,QSA]
 RewriteRule (.*\.html?) {indexFile}?url=/$1 [L,QSA]
 
diff --git a/include/tpl/htaccess_rewrite.tpl b/include/tpl/htaccess_rewrite.tpl
index 26ea1e4..6e863a4 100644
--- a/include/tpl/htaccess_rewrite.tpl
+++ b/include/tpl/htaccess_rewrite.tpl
@@ -20,7 +20,7 @@ RewriteRule ^{PAT_PLUGIN} {indexFile}?url=plugin/$1 [L,QSA]
 RewriteRule ^{PAT_SEARCH} {indexFile}?url=/{PATH_SEARCH}/$1 [L,QSA]
 RewriteRule ^{PAT_CSS} {indexFile}?url=/$1 [L,QSA]
 RewriteRule ^{PAT_AUTHORS} {indexFile}?url=/{PATH_AUTHORS}/$1 [L,QSA]
-RewriteRule ^index\.(html?|php.?) {indexFile}?url=index.html [L,QSA]
+RewriteRule ^index\.(html?|php.+) {indexFile}?url=index.html [L,QSA]
 RewriteRule ^htmlarea/(.*) htmlarea/$1 [L,QSA]
 RewriteRule (.*\.html?) {indexFile}?url=/$1 [L,QSA]
 
-- 
2.39.5