Skip to content
Snippets Groups Projects
Commit ea2a4271 authored by Andreas Gohr's avatar Andreas Gohr
Browse files

only debug when in xhtml mode in parserutils.php

darcs-hash:20070303195008-7ad00-880996042e703973c56d38f803f79555256dbe84.gz
parent fcf93a34
No related branches found
No related tags found
No related merge requests found
......@@ -148,16 +148,16 @@ function p_cached_output($file, $format='xhtml', $id='') {
$cache = new cache_renderer($id, $file, $format);
if ($cache->useCache()) {
$parsed = $cache->retrieveCache();
if($conf['allowdebug']) $parsed .= "\n<!-- cachefile {$cache->cache} used -->\n";
if($conf['allowdebug'] && $format=='xhtml') $parsed .= "\n<!-- cachefile {$cache->cache} used -->\n";
} else {
$parsed = p_render($format, p_cached_instructions($file,false,$id), $info);
if ($info['cache']) {
$cache->storeCache($parsed); //save cachefile
if($conf['allowdebug']) $parsed .= "\n<!-- no cachefile used, but created {$cache->cache} -->\n";
if($conf['allowdebug'] && $format=='xhtml') $parsed .= "\n<!-- no cachefile used, but created {$cache->cache} -->\n";
}else{
$cache->removeCache(); //try to delete cachefile
if($conf['allowdebug']) $parsed .= "\n<!-- no cachefile used, caching forbidden -->\n";
if($conf['allowdebug'] && $format=='xhtml') $parsed .= "\n<!-- no cachefile used, caching forbidden -->\n";
}
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment