Welcome! Log In Create A New Profile

Advanced

Re: Looking for rewrite rules

May 07, 2009 02:54PM
Hallo,


[code]
location / {
rewrite ^/([a-zA-Z_0-9\-]+)/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/([a-zA-Z_0-9\-]+)/$ /browsecategory.php?do=popentries&orderby=$1 last;
rewrite ^/members/([a-zA-Z_0-9\-]+)/page([0-9]+).html$ /browsecategory.php?do=member&userrewrite=$1&page=$2 last;
rewrite ^/members/(([a-zA-Z_0-9]|-)+/?)$ /browsecategory.php?do=member&userrewrite=$1 last;
rewrite ^/([a-zA-Z_0-9\-]+)/members/([a-zA-Z_0-9\-]+)/page([0-9]+).html$ /browsecategory.php?userrewrite=$2&catrewrite=$1&page=$3 last;
rewrite ^/([a-zA-Z_0-9\-]+)/members/(([a-zA-Z_0-9]|-)+/?)$ /browsecategory.php?userrewrite=$2&catrewrite=$1 last;
rewrite ^/([a-zA-Z_0-9\-]+)/(([a-zA-Z_0-9]|-)+)/$ /showentry.php?entryrewrite=$2&catrewrite=$1 last;
rewrite ^/([a-zA-Z_0-9\-]+)/([a-zA-Z_0-9\-]+)/page([0-9]+).html$ /showentry.php?entryrewrite=$2&catrewrite=$1&page=$3 last;
rewrite ^/([a-zA-Z_0-9\-]+)/([a-zA-Z_0-9\-]+)/epage([0-9]+).html$ /showentry.php?entryrewrite=$2&catrewrite=$1&epage=$3 last;
rewrite ^/([a-zA-Z_0-9\-]+)/page([0-9]+).html$ /browsecategory.php?catrewrite=$1&page=$2 last;
rewrite ^/([a-zA-Z_0-9\-]+)/?$ /browsecategory.php?catrewrite=$1 last;
}
[/code]



Das Sollte funktionieren wenn nicht mal fehler meldung.

Kommt in die config vom nginx

Webmaster of www.Pic-City.de



Edited 1 time(s). Last edit at 05/07/2009 02:56PM by TommyGFX.
Subject Author Posted

Looking for rewrite rules

Crazy-Achmet May 07, 2009 09:00AM

Re: Looking for rewrite rules

TommyGFX May 07, 2009 02:54PM

Re: Looking for rewrite rules

Valery Kholodkov May 07, 2009 02:30PM

Re: Looking for rewrite rules

TommyGFX May 07, 2009 04:35PM

Re: Looking for rewrite rules

mow May 07, 2009 05:26PM

Re: Looking for rewrite rules

Crazy-Achmet May 07, 2009 05:18PM



Sorry, only registered users may post in this forum.

Click here to login

Online Users

Guests: 53
Record Number of Users: 6 on February 13, 2018
Record Number of Guests: 421 on December 02, 2018
Powered by nginx      Powered by FreeBSD      PHP Powered      Powered by MariaDB      ipv6 ready