User talk:80686
From MediaWiki.org
If you write me here I'll also answer here. If I wrote on your talk page I'll watch it - answer there.
[edit] NOCACHE extension
- I want something simple - extension that creates an extra magicword __NOCACHE__
- Any page containing the nocache magicword IS never cached by the file caching/mem cache
- I'm using file caching and DynamicPageList2 - The dynamic lists created by DPL2 are cached and not very dynamic
- I'm using 1.8.2 on PHP5 and the newest edition of Dpagelist2
mrshlee@gmail.com
$wgExtensionFunctions[] = 'noCache';
function noCache() {
global $wgHooks, $wgParser;
$wgHooks['ParserBeforeStrip'][]= 'disableCache';
}
function disableCache(&$article, &$text, &$strip_state) {
$counter = 0;
$text = preg_replace( '#__NOCACHE__#', '' , $text , -1 , $counter );
if( $counter > 0 ) {
$article->mTitle->invalidateCache();
}
}
AzaToth 22:00, 26 November 2006 (UTC)
I'll give this a go :)
- Thanks, AzaToth! --80686 14:04, 29 November 2006 (UTC)

