httpd-users-de mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Alexander Lazic <al-httpduser...@none.at>
Subject Re: Abbildung von Verzeichnissen
Date Tue, 01 Nov 2005 18:43:22 GMT
Hi,

On Die 01.11.2005 16:43, René Thiel wrote:
>
>Das heißt, bei der Adresse:
>http://domain.net/12345/termine.php
>soll die Datei:
>http://domain.net/start/termine.php
>ausgeliefert werden, in der Adresszeile des Browsers soll
>aber weiterhin:
>http://domain.net/12345/termine.php
>zu sehen sein.

Ja auf so _*KOMISCHE*_ Ideen kommen auch nur die Kunden ;-(((((

>Zur Zeit habe ich folgende Umleitung in der .htaccess:
>
>RewriteCond %{REQUEST_URI} ^/([0-9]*)$
>RewriteRule ^(.*) /index3.php?%1 [qsappend]
>
>RewriteCond %{REQUEST_URI} ^/([0-9]*)/$
>RewriteRule ^(.*) /index3.php?%1 [qsappend]

Schau dir mal das Flag an:

-- http://httpd.apache.org/docs/2.0/mod/mod_rewrite.html gibts auch im
1.3er

'passthrough|PT' (pass through to next handler)

This flag forces the rewriting engine to set the uri field of the
internal request_rec structure to the value of the filename field. This
flag is just a hack to be able to post-process the output of RewriteRule
directives by Alias, ScriptAlias, Redirect, etc. directives from other
URI-to-filename translators. A trivial example to show the semantics: If
you want to rewrite /abc to /def via the rewriting engine of mod_rewrite
and then /def to /ghi with mod_alias:

---------------------
RewriteRule ^/abc(.*) /def$1 [PT]
Alias /def /ghi
---------------------

If you omit the PT flag then mod_rewrite will do its job fine, i.e., it
rewrites uri=/abc/... to filename=/def/... as a full API-compliant
URI-to-filename translator should do. Then mod_alias comes and tries to
do a URI-to-filename transition which will not work.

Note: You have to use this flag if you want to intermix directives of
different modules which contain URL-to-filename translators. The typical
example is the use of mod_alias and mod_rewrite..
---

Hth

Aleks

--------------------------------------------------------------------------
                Apache HTTP Server Mailing List "users-de" 
      unsubscribe-Anfragen an users-de-unsubscribe@httpd.apache.org
           sonstige Anfragen an users-de-help@httpd.apache.org
--------------------------------------------------------------------------


Mime
View raw message