Skip to content

Instantly share code, notes, and snippets.

@miya0001
Created May 6, 2011 12:21
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save miya0001/958855 to your computer and use it in GitHub Desktop.
Save miya0001/958855 to your computer and use it in GitHub Desktop.
Do not cache mobile theme of wptouch with quick cache
<?php
/*
Plugin Name: Disable Quick Cache with WPtouch
Author: Takayuki Miyauchi
*/
add_filter('theme_root', 'disable_quick_cache', 9999);
function disable_quick_cache($path){
if (preg_match("/plugins\/wptouch/", $path)) {
define("DONOTCACHEPAGE", true);
define("QUICK_CACHE_ALLOWED", false);
$_SERVER["QUICK_CACHE_ALLOWED"] = false;
}
return $path;
}
?>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment