]> granicus.if.org Git - apache/commitdiff
Adds [NE] to the canonical hostname rules, as requested in
authorRich Bowen <rbowen@apache.org>
Wed, 13 May 2009 01:36:04 +0000 (01:36 +0000)
committerRich Bowen <rbowen@apache.org>
Wed, 13 May 2009 01:36:04 +0000 (01:36 +0000)
https://issues.apache.org/bugzilla/show_bug.cgi?id=47186

git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@774161 13f79535-47bb-0310-9956-ffa450edef68

docs/manual/rewrite/rewrite_guide.html.en
docs/manual/rewrite/rewrite_guide.xml

index 958448c65eaad2948724a828369ba9f70ced996a..e14b991b812e883849ece94403e2d78a966bbacc 100644 (file)
@@ -120,14 +120,14 @@ RewriteRule   ^/u/(<strong>[^/]+</strong>)$  /$1/$2<strong>/</strong>   [<strong
 RewriteCond %{HTTP_HOST}   !^www\.example\.com [NC]
 RewriteCond %{HTTP_HOST}   !^$
 RewriteCond %{SERVER_PORT} !^80$
-RewriteRule ^/?(.*)         http://www.example.com:%{SERVER_PORT}/$1 [L,R]
+RewriteRule ^/?(.*)         http://www.example.com:%{SERVER_PORT}/$1 [L,R,NE]
 </pre></div>
 
 <p>And for a site running on port 80</p>
 <div class="example"><pre>
 RewriteCond %{HTTP_HOST}   !^www\.example\.com [NC]
 RewriteCond %{HTTP_HOST}   !^$
-RewriteRule ^/?(.*)         http://www.example.com/$1 [L,R]
+RewriteRule ^/?(.*)         http://www.example.com/$1 [L,R,NE]
 </pre></div>
 
         <p>
@@ -140,7 +140,7 @@ RewriteRule ^/?(.*)         http://www.example.com/$1 [L,R]
 <div class="example"><pre>
 RewriteCond %{HTTP_HOST} !^www\. [NC]
 RewriteCond %{HTTP_HOST} !^$
-RewriteRule ^/?(.*) http://www.%{HTTP_HOST}/$1 [L,R]
+RewriteRule ^/?(.*) http://www.%{HTTP_HOST}/$1 [L,R,NE]
 </pre></div>
 
     <p>These rulesets will work either in your main server configuration
index 9c38a9bc9c5936787f1bece9aeda8252ceb33679..937d4b4163b84a8bfd4a26dfe1a377bf88d0b7b5 100644 (file)
@@ -109,14 +109,14 @@ RewriteRule   ^/u/(<strong>[^/]+</strong>)$  /$1/$2<strong>/</strong>   [<strong
 RewriteCond %{HTTP_HOST}   !^www\.example\.com [NC]
 RewriteCond %{HTTP_HOST}   !^$
 RewriteCond %{SERVER_PORT} !^80$
-RewriteRule ^/?(.*)         http://www.example.com:%{SERVER_PORT}/$1 [L,R]
+RewriteRule ^/?(.*)         http://www.example.com:%{SERVER_PORT}/$1 [L,R,NE]
 </pre></example>
 
 <p>And for a site running on port 80</p>
 <example><pre>
 RewriteCond %{HTTP_HOST}   !^www\.example\.com [NC]
 RewriteCond %{HTTP_HOST}   !^$
-RewriteRule ^/?(.*)         http://www.example.com/$1 [L,R]
+RewriteRule ^/?(.*)         http://www.example.com/$1 [L,R,NE]
 </pre></example>
 
         <p>
@@ -129,7 +129,7 @@ RewriteRule ^/?(.*)         http://www.example.com/$1 [L,R]
 <example><pre>
 RewriteCond %{HTTP_HOST} !^www\. [NC]
 RewriteCond %{HTTP_HOST} !^$
-RewriteRule ^/?(.*) http://www.%{HTTP_HOST}/$1 [L,R]
+RewriteRule ^/?(.*) http://www.%{HTTP_HOST}/$1 [L,R,NE]
 </pre></example>
 
     <p>These rulesets will work either in your main server configuration