X-Git-Url: https://granicus.if.org/sourcecode?a=blobdiff_plain;f=docs%2Fmanual%2Fmod%2Fmod_rewrite.html.en;h=e310b299f886c0ed93d159f2298675fadf3039bb;hb=d4f82636073731f93c93eee1de7fa8d394bd539e;hp=c4cf75977e498066ea8c40226fe2e0fc369ac8f7;hpb=c04bbf3c9b99a26d6c81b2972246d54a0c942f0e;p=apache diff --git a/docs/manual/mod/mod_rewrite.html.en b/docs/manual/mod/mod_rewrite.html.en index c4cf75977e..e310b299f8 100644 --- a/docs/manual/mod/mod_rewrite.html.en +++ b/docs/manual/mod/mod_rewrite.html.en @@ -5,7 +5,7 @@ This file is generated from xml source: DO NOT EDIT XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX --> -
struct tm
fields of the Unix system.
- Most are documented elsewhere in the Manual or in
- the CGI specification.
+ Most are documented here
+ or elsewhere in the Manual or in the CGI specification.
SERVER_NAME and SERVER_PORT depend on the values of
UseCanonicalName
and
@@ -290,14 +295,6 @@ Alias /myapp /opt/myapp-1.2.3
Those that are special to mod_rewrite include those below.
IS_SUBREQ
API_VERSION
THE_REQUEST
CONN_REMOTE_ADDR
GET
- /index.html HTTP/1.1
"). This does not
- include any additional headers sent by the
- browser. This value has not been unescaped
- (decoded), unlike most other variables below.mod_remoteip
module).REQUEST_URI
HTTPS
QUERY_STRING
.mod_ssl
is loaded).IS_SUBREQ
REMOTE_ADDR
mod_remoteip
module).REQUEST_FILENAME
REQUEST_URI
to map the request to a file.
- HTTPS
mod_ssl
is loaded).REQUEST_SCHEME
ServerName
.REMOTE_ADDR
mod_remoteip
module).REQUEST_URI
CONN_REMOTE_ADDR
mod_remoteip
module).QUERY_STRING
.THE_REQUEST
GET
+ /index.html HTTP/1.1
"). This does not
+ include any additional headers sent by the
+ browser. This value has not been unescaped
+ (decoded), unlike most other variables below.Proxy-Connection:
''.
If a HTTP header is used in a condition this header is added to - the Vary header of the response in case the condition evaluates to + the Vary header of the response in case the condition evaluates to true for the request. It is not added if the condition evaluates to false for the request. Adding the HTTP header to the Vary header of the response is needed for proper caching.
@@ -729,7 +736,7 @@ RewriteRule ^/$ /homepage.std.html [L] all. It does not even update theSCRIPT_URx
environment variables.
- Use this directive to disable rules in a particular contact, +
Use this directive to disable rules in a particular context,
rather than commenting out all the RewriteRule
directives.
Note that rewrite configurations are not
@@ -1169,136 +1176,134 @@ cannot use $N
in the substitution string!
brackets, of any of the flags in the following table. More
details, and examples, for each flag, are available in the Rewrite Flags document.
Flag and syntax | +
---|
Flag and syntax | Function |
---|---|
B | Escape non-alphanumeric characters in backreferences before applying the transformation. details ... |
backrefnoplus|BNP | If backreferences are being escaped, spaces should be escaped to %20 instead of +. Useful when the backreference will be used in the path component rather than the query string.details ... |
chain|C | Rule is chained to the following rule. If the rule fails, the rule(s) chained to it will be skipped. details ... |
cookie|CO=NAME:VAL | Sets a cookie in the client browser. Full syntax is: CO=NAME:VAL:domain[:lifetime[:path[:secure[:httponly]]]] details ... |
discardpath|DPI | Causes the PATH_INFO portion of the rewritten URI to be discarded. details ... |
END | Stop the rewriting process immediately and don't apply any more rules. Also prevents further execution of rewrite rules in per-directory and .htaccess context. (Available in 2.3.9 and later) details ... |
env|E=[!]VAR[:VAL] | Causes an environment variable VAR to be set (to the value VAL if provided). The form !VAR causes the environment variable VAR to be unset. details ... |
forbidden|F | Returns a 403 FORBIDDEN response to the client browser. details ... |
gone|G | Returns a 410 GONE response to the client browser. details ... |
Handler|H=Content-handler | Causes the resulting URI to be sent to the specified Content-handler for processing. details ... |
last|L | Stop the rewriting process immediately and don't apply any more rules. Especially note caveats for per-directory and .htaccess context (see also the END flag). details ... |
next|N | Re-run the rewriting process, starting again with the first rule, using the result of the ruleset so far as a starting point. details ... |
nocase|NC | Makes the pattern comparison case-insensitive. details ... |
noescape|NE | Prevent mod_rewrite from applying hexcode escaping of special characters in the result of the rewrite. details ... |
nosubreq|NS | Causes a rule to be skipped if the current request is an internal sub-request. details ... |
proxy|P | Force the substitution URL to be internally sent as a proxy request. details ... |
passthrough|PT | Forces the resulting URI to be passed back to the URL
mapping engine for processing of other URI-to-filename
translators, such as Alias or
Redirect . details ... |
qsappend|QSA | Appends any query string from the original request URL to any query string created in the rewrite target.details ... |
qsdiscard|QSD | Discard any query string attached to the incoming URI. details ... |
redirect|R[=code] | Forces an external redirect, optionally with the specified HTTP status code. details ... |
skip|S=num | Tells the rewriting engine to skip the next num rules if the current rule matches. details ... |
type|T=MIME-type | Force the MIME-type of the target file to be the specified type. details ... |
When the substitution string begins with a string @@ -1321,68 +1326,55 @@ directive.
/somepath/pathinfo'':Given Rule | Resulting Substitution | ||||||||||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
^/somepath(.*) otherpath$1 | invalid, not supported | ||||||||||||||||||||||||
^/somepath(.*) otherpath$1 [R] | invalid, not supported | ||||||||||||||||||||||||
^/somepath(.*) otherpath$1 [P] | invalid, not supported | ||||||||||||||||||||||||
^/somepath(.*) /otherpath$1 | /otherpath/pathinfo | ||||||||||||||||||||||||
^/somepath(.*) /otherpath$1 [R] | http://thishost/otherpath/pathinfo via external redirection | ||||||||||||||||||||||||
^/somepath(.*) /otherpath$1 [P] | doesn't make sense, not supported | ||||||||||||||||||||||||
^/somepath(.*) http://thishost/otherpath$1 | /otherpath/pathinfo | ||||||||||||||||||||||||
^/somepath(.*) http://thishost/otherpath$1 [R] | http://thishost/otherpath/pathinfo via external redirection | ||||||||||||||||||||||||
^/somepath(.*) http://thishost/otherpath$1 [P] | doesn't make sense, not supported | ||||||||||||||||||||||||
^/somepath(.*) http://otherhost/otherpath$1 | http://otherhost/otherpath/pathinfo via external redirection | ||||||||||||||||||||||||
^/somepath(.*) http://otherhost/otherpath$1 [R] | http://otherhost/otherpath/pathinfo via external redirection (the [R] flag is redundant) | ||||||||||||||||||||||||
^/somepath(.*) http://otherhost/otherpath$1 [P] | http://otherhost/otherpath/pathinfo via internal proxy |
Given Rule | Resulting Substitution |
---|---|
^localpath(.*) otherpath$1 | /somepath/otherpath/pathinfo |
^localpath(.*) otherpath$1 [R] | http://thishost/somepath/otherpath/pathinfo via external redirection |
^localpath(.*) otherpath$1 [P] | doesn't make sense, not supported |
^localpath(.*) /otherpath$1 | /otherpath/pathinfo |
^localpath(.*) /otherpath$1 [R] | http://thishost/otherpath/pathinfo via external redirection |
^localpath(.*) /otherpath$1 [P] | doesn't make sense, not supported |
^localpath(.*) http://thishost/otherpath$1 | /otherpath/pathinfo |
^localpath(.*) http://thishost/otherpath$1 [R] | http://thishost/otherpath/pathinfo via external redirection |
^localpath(.*) http://thishost/otherpath$1 [P] | doesn't make sense, not supported |
^localpath(.*) http://otherhost/otherpath$1 | http://otherhost/otherpath/pathinfo via external redirection |
^localpath(.*) http://otherhost/otherpath$1 [R] | http://otherhost/otherpath/pathinfo via external redirection (the [R] flag is redundant) |
^localpath(.*) http://otherhost/otherpath$1 [P] | http://otherhost/otherpath/pathinfo via internal proxy |