WordPress 3.0 & nginx - permalink, 404 problem

前端 未结 8 2066
清歌不尽
清歌不尽 2021-02-08 16:26

I\'ve installed nginx, FastCGI and PHP on my server. WordPress 3.0 installed after a bit of a monster battle, but it\'s installed and working well.

However, when I chang

8条回答
  •  再見小時候
    2021-02-08 16:34

    this does not work if you are using location other than / like:

    ~ .php$, what i meant to say that pretty link will work but your graphics will be all over the place. so what you need is exactly stated below.

    http://www.pearlin.info

      location ~ \.php$
    
    
    
       {
            try_files $uri $uri/ /index.php?$uri&$args;
            fastcgi_split_path_info ^(.+\.php)(/.+)$;
            fastcgi_pass 127.0.0.1:9000;
            fastcgi_index index.php;
            fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
            include fastcgi_params;
        }
    
      if (!-e $request_filename){
        rewrite ^(.*)$ /index.php?url=$1 break;
      }
    

提交回复
热议问题