Wordpress 3.0 wp super cache rewrite rule?

Does anyone know the nginx rewrite rule for wordpress 3.0 wp super cache
(multi site)?

I found an example on this site:
http://kuapp.com/2010/06/30/nginx-rewrite-rules-of-wordpress-3-0-permalinks-and-wp-super-cache.html

But I am not sure whether this can work with multi site. Thanks a lot.

Max

On 03.08.2010 12:29, Max wrote:

Does anyone know the nginx rewrite rule for wordpress 3.0 wp super cache
(multi site)?

I found an example on this site:
http://kuapp.com/2010/06/30/nginx-rewrite-rules-of-wordpress-3-0-permalinks-and-wp-super-cache.html

But I am not sure whether this can work with multi site. Thanks a lot.

Max

Hi,

I have only:

try_files $uri $uri/ /index.php?q=$uri&$args;

and looks like ‘wp-super-cache’ on mine wordpress3 work flawless, but it
is not wordpress MU, just one blog.

With this rule I was able to set any permalinks type what I want.

– Piotr.

Hi Piotr,

Thanks. I tried your rewrite rule, but it seems it doesn’t work with
multisite. I can’t see any cache page generated.

Your rewrite rule is interesing, so simple, but as long as it get thing
done, it’s ok. I used to use the following rule to make the permalinks
works.

rewrite ^./files/(.)$ /wp-includes/ms-files.php?file=$1 last;
if (!-e $request_filename) {
rewrite ^.+?(/wp-.) $1 last;
rewrite ^.+?(/.
.php)$ $1 last;
rewrite ^ /index.php last;
}

Max

On 04.08.2010 12:06, Max wrote:

Hi Piotr,

Thanks. I tried your rewrite rule, but it seems it doesn’t work with
multisite. I can’t see any cache page generated.

You need change something in wp-super-cache for MU if I remember correct
(check readme.txt).

Your rewrite rule is interesing, so simple, but as long as it get thing
done, it’s ok. I used to use the following rule to make the permalinks
works.

rewrite ^./files/(.)$ /wp-includes/ms-files.php?file=$1 last;
if (!-e $request_filename) {
rewrite ^.+?(/wp-.) $1 last;
rewrite ^.+?(/.
.php)$ $1 last;
rewrite ^ /index.php last;
}

Well I not fully understand your 2nd rule, with ! -e but it is working?
You rewritting all requests targeted to non-existing files to 3 others
thing? Last rewrite doing the same thing what nginx’s try_files.

I have on the end of my blog (generated page):

So it’s working for me.

– Piotr.

This forum is not affiliated to the Ruby language, Ruby on Rails framework, nor any Ruby applications discussed here.

| Privacy Policy | Terms of Service | Remote Ruby Jobs