WordPress伪静态设置


1.修改Nginx或宝塔终端配置

        location / {
    rewrite /wp-admin$ $scheme://$host$uri/ permanent;

        if (-f $request_filename/index.html){
            rewrite (.*) $1/index.html break;
        }
        if (-f $request_filename/index.php){
            rewrite (.*) $1/index.php;
        }
        if (!-f $request_filename){
            rewrite (.*) /index.php;
         }
        }

2.Wordpress 页面修改