can not make WordPress pretty permalinks work (404 error)

Edho Arief edho at myconan.net
Wed May 9 12:18:14 UTC 2012


On Wed, May 9, 2012 at 6:50 PM, seron <nginx-forum at nginx.us> wrote:
> I've tried to follow the guide at
> http://www.howtoforge.com/running-wordpress-on-nginx-lemp-on-debian-squeeze-ubuntu-11.04
> as suggested in the post
> http://forum.nginx.org/read.php?2,222511,222517#msg-222517 , but it
> still doesn't work. I've copied and replaced the server settings from
> the guide, and changed the parts pertaining to my server.
>
> Any permalink setting other than default results in a 404 error page
> when accessing the permalink. The permalinks all have the form
> http://wp.dev/sitename/sample-page. There's no structure created for the
> tags month, year etc. in the url.
>

This may be able to help (my wordpress config).

location / {
  root /home/edho/sites/animebsd.net;
  index index.php;
  try_files $uri $uri/ /index.php?q=$uri&$args;
  expires max;
  location ~ \.php$ {
    expires off;
    try_files $uri =404;
    fastcgi_param SCRIPT_FILENAME $request_filename;
    include fastcgi_params;
    fastcgi_pass unix:/tmp/.php.sock-edho;
  }
}



More information about the nginx mailing list