星期五, 七月 17, 2009

gallery3的nginx rewrite规则

URL为:http://domain/gallery3,则rewrite规则为如下:
location /gallery3 {
if (-f $request_filename) {
expires max;
break;
}
if (!-e $request_filename) {
rewrite ^/gallery3/index.php/(.+)$ /gallery3/index.php?kohana_uri=$1 last;
}
}

没有评论: