all repos — wp-ffpc @ fe07b27754afec0bf29729ab8d1db2cdaf9d6eed

scheme added to key

git-svn-id: http://plugins.svn.wordpress.org/wp-ffpc/trunk@586168 b8457f37-d9ea-0310-8a92-e5e31aec5664
cadeyrn cadeyrn@b8457f37-d9ea-0310-8a92-e5e31aec5664
Thu, 16 Aug 2012 10:33:56 +0000
commit

fe07b27754afec0bf29729ab8d1db2cdaf9d6eed

parent

0b3f7eb9aebba1f675d1c5a193333fc9284f9ee5

4 files changed, 12 insertions(+), 8 deletions(-)

jump to
M advanced-cache.phpadvanced-cache.php

@@ -65,10 +65,13 @@ return false;

/* use the full accessed URL string as key, same will be generated by nginx as well we need a data and a meta key: data is string only with content, meta is not used in nginx */ +global $wp_ffpc_data_key_protocol; +$wp_ffpc_data_key_protocol = empty ( $_SERVER['HTTPS'] ) ? 'http://' : 'https://'; + global $wp_ffpc_data_key; -$wp_ffpc_data_key = $wp_ffpc_config['prefix_data'] . $_SERVER['HTTP_HOST'] . $wp_ffpc_uri; +$wp_ffpc_data_key = $wp_ffpc_config['prefix_data'] . $wp_ffpc_data_key_protocol . $_SERVER['HTTP_HOST'] . $wp_ffpc_uri; global $wp_ffpc_meta_key; -$wp_ffpc_meta_key = $wp_ffpc_config['prefix_meta'] . $_SERVER['HTTP_HOST'] . $wp_ffpc_uri; +$wp_ffpc_meta_key = $wp_ffpc_config['prefix_meta'] . $wp_ffpc_data_key_protocol . $_SERVER['HTTP_HOST'] . $wp_ffpc_uri; /* search for valid meta entry */ global $wp_ffpc_meta;
M nginx-sample.confnginx-sample.conf

@@ -10,7 +10,7 @@

location @memcached { default_type text/html; - set $memcached_key DATAPREFIX$host$request_uri; + set $memcached_key DATAPREFIX$scheme://$host$request_uri; memcached_pass MEMCACHEDHOST:MEMCACHEDPORT; error_page 404 = @rewrites; }

@@ -18,10 +18,8 @@

location @rewrites { rewrite ^(.*)$ /index.php?q=$1 last; } - + ... } } ... - -
M readme.txtreadme.txt

@@ -69,11 +69,13 @@ == Changelog ==

= 0.4 = 2012.08.06 + * tested against new WordPress versions * added lines to "memcached" storage to be able to work with nginx as well * added lines to "memcached" to use binary protocol ( tested with PHP Memcached version 2.0.1 ) KNOWN ISSUES + * "memcache" extension fails in binary mode; the reason is under investigation = 0.3.2 =
M wp-ffpc-common.phpwp-ffpc-common.php

@@ -102,8 +102,9 @@ {

$path = substr ( get_permalink($post_id) , 7 ); if (empty($path)) return false; - $meta = $wp_ffpc_config['prefix-meta'] . $path; - $data = $wp_ffpc_config['prefix-data'] . $path; + $wp_ffpc_data_key_protocol = empty ( $_SERVER['HTTPS'] ) ? 'http://' : 'https://'; + $meta = $wp_ffpc_config['prefix-meta'] . $wp_ffpc_data_key_protocol . $path; + $data = $wp_ffpc_config['prefix-data'] . $wp_ffpc_data_key_protocol . $path; } switch ($wp_ffpc_config['cache_type'])