location / {
if (!-e $request_filename) {
rewrite ^/youhua/(.[a-zA-Z0-9\-\_]+)/(.[0-9]*).html$ /youhua/index.php?class=$1&view=$2 last;
rewrite ^/article-(.[0-9]*).html$ /index.php?mod=article&id=$1 last;
rewrite ^/blog/(.[a-zA-Z0-9\-\_]+)/(.[0-9]*).html$ /blog/index.php?class=$1&view=$2 last;
rewrite ^/(.[0-9]*).html$ /blog/index.php?mod=article&id=$1 last;
rewrite ^/(.[a-zA-Z0-9\-\_]+).html$ /index.php?mod=$1 last;
}
}
上面是网站的伪静态,但是红色标注的那段规则在实际网站打开中无效果,打开报错404

|
|