summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorSteven Jones2012-01-07 09:57:49 +0000
committerSteven Jones2012-01-07 09:59:31 +0000
commitc98257fe29872db3b54fdbd4bf40b434a4ce588c (patch)
tree51fcafc2926f9cbc8f75220515554e086ec3d71e
parent7f273f10d2c6f133bdcd438cb7acc605b02c5fa2 (diff)
Issue #1396326 by Steven Jones: Fixed Mod rewrite double escapes URLs.7.x-2.x
-rw-r--r--http/apache/vhost.tpl.php6
-rw-r--r--http/apache_ssl/vhost_ssl.tpl.php2
2 files changed, 4 insertions, 4 deletions
diff --git a/http/apache/vhost.tpl.php b/http/apache/vhost.tpl.php
index be7ae0c..61da1c3 100644
--- a/http/apache/vhost.tpl.php
+++ b/http/apache/vhost.tpl.php
@@ -30,16 +30,16 @@ if ($this->redirection || $ssl_redirection) {
if ($ssl_redirection && !$this->redirection) {
// redirect aliases in non-ssl to the same alias on ssl.
- print " RewriteRule ^/*(.*)$ https://%{HTTP_HOST}/$1 [L,R=301]\n";
+ print " RewriteRule ^/*(.*)$ https://%{HTTP_HOST}/$1 [NE,L,R=301]\n";
}
elseif ($ssl_redirection && $this->redirection) {
// redirect all aliases + main uri to the main https uri.
- print " RewriteRule ^/*(.*)$ https://{$this->uri}/$1 [L,R=301]\n";
+ print " RewriteRule ^/*(.*)$ https://{$this->uri}/$1 [NE,L,R=301]\n";
}
elseif (!$ssl_redirection && $this->redirection) {
// Redirect all aliases to the main http url.
print " RewriteCond %{HTTP_HOST} !^{$this->uri}$ [NC]\n";
- print " RewriteRule ^/*(.*)$ http://{$this->uri}/$1 [L,R=301]\n";
+ print " RewriteRule ^/*(.*)$ http://{$this->uri}/$1 [NE,L,R=301]\n";
}
}
?>
diff --git a/http/apache_ssl/vhost_ssl.tpl.php b/http/apache_ssl/vhost_ssl.tpl.php
index 58a9994..1816f06 100644
--- a/http/apache_ssl/vhost_ssl.tpl.php
+++ b/http/apache_ssl/vhost_ssl.tpl.php
@@ -43,7 +43,7 @@ if (sizeof($this->aliases)) {
// Redirect all aliases to the main https url.
print " RewriteCond %{HTTP_HOST} !^{$this->uri}$ [NC]\n";
- print " RewriteRule ^/*(.*)$ https://{$this->uri}/$1 [L,R=301]\n";
+ print " RewriteRule ^/*(.*)$ https://{$this->uri}/$1 [NE,L,R=301]\n";
}
}
?>