From: Rich Bowen Date: Fri, 13 Nov 2009 12:36:04 +0000 (+0000) Subject: Removes an inscrutable recipe - I don't know what problem it's trying to X-Git-Tag: 2.3.4~55 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=18c93400300d689c7386cfa722cbbb11e883b2e9;p=thirdparty%2Fapache%2Fhttpd.git Removes an inscrutable recipe - I don't know what problem it's trying to solve, and the solution appears to be a completely useless use of RewriteMap to solve a trivial problem that could be better done with Alias. Am I missing something? git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@835824 13f79535-47bb-0310-9956-ffa450edef68 --- diff --git a/docs/manual/rewrite/rewrite_guide.html.en b/docs/manual/rewrite/rewrite_guide.html.en index 4c27d4543f9..b05eaed87be 100644 --- a/docs/manual/rewrite/rewrite_guide.html.en +++ b/docs/manual/rewrite/rewrite_guide.html.en @@ -47,7 +47,6 @@
  • Redirect Homedirs For Foreigners
  • Redirecting Anchors
  • Time-Dependent Rewriting
  • -
  • External Rewriting Engine
  • Structured Homedirs
  • Dynamic Mirror
  • Retrieve Missing Data from Intranet
  • @@ -298,60 +297,6 @@ RewriteRule ^foo\.html$ foo.night.html
    top
    -

    External Rewriting Engine

    - - - -
    -
    Description:
    - -
    -

    A FAQ: How can we solve the FOO/BAR/QUUX/etc. - problem? There seems no solution by the use of - mod_rewrite...

    -
    - -
    Solution:
    - -
    -

    Use an external RewriteMap, i.e. a program which acts - like a RewriteMap. It is run once on startup of Apache - receives the requested URLs on STDIN and has - to put the resulting (usually rewritten) URL on - STDOUT (same order!).

    - -
    -RewriteEngine on
    -RewriteMap    quux-map       prg:/path/to/map.quux.pl
    -RewriteRule   ^/~quux/(.*)$  /~quux/${quux-map:$1}
    -
    - -
    -#!/path/to/perl
    -
    -#   disable buffered I/O which would lead
    -#   to deadloops for the Apache server
    -$| = 1;
    -
    -#   read URLs one per line from stdin and
    -#   generate substitution URL on stdout
    -while (<>) {
    -    s|^foo/|bar/|;
    -    print $_;
    -}
    -
    - -

    This is a demonstration-only example and just rewrites - all URLs /~quux/foo/... to - /~quux/bar/.... Actually you can program - whatever you like. But notice that while such maps can be - used also by an average user, only the - system administrator can define it.

    -
    -
    - -
    top
    -

    Structured Homedirs

    diff --git a/docs/manual/rewrite/rewrite_guide.xml b/docs/manual/rewrite/rewrite_guide.xml index 5e52db3fa31..91f2ea9b546 100644 --- a/docs/manual/rewrite/rewrite_guide.xml +++ b/docs/manual/rewrite/rewrite_guide.xml @@ -292,62 +292,6 @@ RewriteRule ^foo\.html$ foo.night.html -
    - - External Rewriting Engine - -
    -
    Description:
    - -
    -

    A FAQ: How can we solve the FOO/BAR/QUUX/etc. - problem? There seems no solution by the use of - mod_rewrite...

    -
    - -
    Solution:
    - -
    -

    Use an external RewriteMap, i.e. a program which acts - like a RewriteMap. It is run once on startup of Apache - receives the requested URLs on STDIN and has - to put the resulting (usually rewritten) URL on - STDOUT (same order!).

    - -
    -RewriteEngine on
    -RewriteMap    quux-map       prg:/path/to/map.quux.pl
    -RewriteRule   ^/~quux/(.*)$  /~quux/${quux-map:$1}
    -
    - -
    -#!/path/to/perl
    -
    -#   disable buffered I/O which would lead
    -#   to deadloops for the Apache server
    -$| = 1;
    -
    -#   read URLs one per line from stdin and
    -#   generate substitution URL on stdout
    -while (<>) {
    -    s|^foo/|bar/|;
    -    print $_;
    -}
    -
    - -

    This is a demonstration-only example and just rewrites - all URLs /~quux/foo/... to - /~quux/bar/.... Actually you can program - whatever you like. But notice that while such maps can be - used also by an average user, only the - system administrator can define it.

    -
    -
    - -
    -
    Structured Homedirs