Looking for rewrite rules
Valery Kholodkov
valery+nginxen at grid.net.ru
Thu May 7 22:30:46 MSD 2009
Weiss nicht ob es korrekt ist, schaut aber beeindruckend. Vielleicht es ist eine gute Idee einen automatischen Übersetzer zu erstellen.
----- "TommyGFX" <nginx-forum at nginx.us> wrote:
> Hallo,
>
>
>
> location / {
> rewrite ^(+)/robots\.txt$ robots.txt last;
> rewrite ^members/page([0-9]+).html$ index.php?page=$1 last;
> rewrite ^whatsnew/entries/([0-9]+)/page([0-9]+).html$
> browsecategory.php?do=newentries&cutoffdate=$1&page=$2 last;
> rewrite ^whatsnew/entries/(([0-9]?|-)+/?)$
> browsecategory.php?do=newentries&cutoffdate=$1 last;
> rewrite ^whatsnew/posts/([0-9]+)/page([0-9]+).html$
> browsecategory.php?do=newposts&cutoffdate=$1&page=$2 last;
> rewrite ^whatsnew/posts/(([0-9]?|-)+/?)$
> browsecategory.php?do=newposts&cutoffdate=$1 last;
> rewrite ^whatspopular/(+)/$
> browsecategory.php?do=popentries&orderby=$1 last;
> rewrite ^members/(+)/page([0-9]+).html$
> browsecategory.php?do=member&userrewrite=$1&page=$2 last;
> rewrite ^members/((|-)+/?)$
> browsecategory.php?do=member&userrewrite=$1 last;
> rewrite ^(+)/members/(+)/page([0-9]+).html$
> browsecategory.php?userrewrite=$2&catrewrite=$1&page=$3 last;
> rewrite ^(+)/members/((|-)+/?)$
> browsecategory.php?userrewrite=$2&catrewrite=$1 last;
> rewrite ^(+)/((|-)+)/$ showentry.php?entryrewrite=$2&catrewrite=$1
> last;
> rewrite ^(+)/(+)/page([0-9]+).html$
> showentry.php?entryrewrite=$2&catrewrite=$1&page=$3 last;
> rewrite ^(+)/(+)/epage([0-9]+).html$
> showentry.php?entryrewrite=$2&catrewrite=$1&epage=$3 last;
> rewrite ^(+)/page([0-9]+).html$
> browsecategory.php?catrewrite=$1&page=$2 last;
> rewrite ^(+)/?$ browsecategory.php?catrewrite=$1 last;
> }
>
>
>
>
> Das Sollte funktionieren wenn nicht mal fehler meldung.
>
> Kommt in die config vom nginx
>
> Posted at Nginx Forum:
> http://forum.nginx.org/read.php?2,1853,1861#msg-1861
--
MfG,
Valery Kholodkov
More information about the nginx
mailing list