location / {
#手机版伪静态规则
rewrite ^/m/$ /plus/rewrite.php?s=$1&mobile=1 last;
rewrite ^/m/index\.html$ /plus/rewrite.php?s=$1&mobile=1 last;
#PC版伪静态规则
rewrite ^/sitemap\.xml$ /sitemap.php;
rewrite ^/$ /plus/rewrite.php?s=$1 last;
rewrite ^/index\.html$ /plus/rewrite.php?s=$1 last;
if (!-e $request_filename) {
rewrite ^/m/(.*)$ /plus/rewrite.php?s=$1&mobile=1 last;
rewrite ^/(.*)$ /plus/rewrite.php?s=$1 last;
rewrite ^(.*)$ /plus/rewrite.php?s=$1 last;
}
rewrite ^/tags\.html$ /tags.php;
rewrite ^/tags/(.*)-([0-9]+)\.html$ /tags.php?\/$1\/$2;
rewrite ^/tags/(.*)\.html$ /tags.php?\/$1;
}
rewrite ^/images\/(.*?)\.jpg$ /images/pic.php?k=$1;