On Mon, Aug 31, 2009 at 06:36:24PM +1000, Jeff Waugh wrote:
>
>
> > set $wordpress_root /srv/wordpress/root;
>
> Should've mentioned:
>
> root /srv/example.com/root;
>
> > location / {
> > try_files $uri $uri/ @wordroot;
> > }
> >
> > location @wordroot {
> > internal;
> > root $wordpress_root;
> > index index.php;
> > try_files $uri $uri/ /index.php?q=$request_uri;
> > expires 5y;
> > }
>
> The point behind the above logic is to try and serve a file first from the
> domain's root (such as favicon.ico), then from the generic $wordpress_root
> for files provided by the WordPress distribution (such as everything under
> /wp-includes as with the .js example in the debugging), then finally pass
> anything else to PHP.
The patch.
--
Igor Sysoev
http://sysoev.ru/en/