From: Geoffrey T. D. <da...@us...> - 2003-02-26 02:55:56
|
Update of /cvsroot/phpwiki/phpwiki In directory sc8-pr-cvs1:/tmp/cvs-serv15617 Modified Files: index.php Log Message: New config settings in index.php to control cache control strictness. Index: index.php =================================================================== RCS file: /cvsroot/phpwiki/phpwiki/index.php,v retrieving revision 1.103 retrieving revision 1.104 diff -u -2 -b -p -d -r1.103 -r1.104 --- index.php 22 Feb 2003 19:43:50 -0000 1.103 +++ index.php 26 Feb 2003 02:55:52 -0000 1.104 @@ -162,4 +162,50 @@ define("MINOR_EDIT_TIMEOUT", 7 * 24 * 36 //define('COMPRESS_OUTPUT', false); + +// CACHE_CONTROL +// +// This controls how PhpWiki sets the HTTP cache control +// headers (Expires: and Cache-Control:) +// +// Choose one of: +// +// NONE: This is roughly the old (pre 1.3.4) behavior. PhpWiki will +// instruct proxies and browsers never to cache PhpWiki output. +// +// STRICT: Cached pages will be invalidated whenever the database global +// timestamp changes. This should behave just like NONE (modulo +// bugs in PhpWiki and your proxies and browsers), except that +// things will be slightly more efficient. +// +// LOOSE: Cached pages will be invalidated whenever they are edited, +// or, if the pages include plugins, when the plugin output could +// concievably have changed. +// +// Behavior should be much like STRICT, except that sometimes +// wikilinks will show up as undefined (with the question mark) +// when in fact they refer to (recently) created pages. +// (Hitting your browsers reload or perhaps shift-reload button +// should fix the problem.) +// +// ALLOW_STALE: Proxies and browsers will be allowed to used stale pages. +// (The timeout for stale pages is controlled by CACHE_CONTROL_MAX_AGE.) +// +// This setting will result in quirky behavior. When you edit a +// page your changes may not show up until you shift-reload the +// page, etc... +// +// This setting is generally not advisable, however it may be useful +// in certain cases (e.g. if your wiki gets lots of page views, +// and few edits by knowledgable people who won't freak over the quirks.) +// +// The default is currently LOOSE. +// +if (!defined('CACHE_CONTROL')) define('CACHE_CONTROL', 'LOOSE'); + +// Maximum page staleness, in seconds. +// +// This only has effect if CACHE_CONTROL is set to ALLOW_STALE. +if (!defined('CACHE_CONTROL_MAX_AGE')) define('CACHE_CONTROL_MAX_AGE', 600); + ///////////////////////////////////////////////////////////////////// // @@ -693,4 +739,7 @@ if (defined('VIRTUAL_PATH') and defined( // $Log$ +// Revision 1.104 2003/02/26 02:55:52 dairiki +// New config settings in index.php to control cache control strictness. +// // Revision 1.103 2003/02/22 19:43:50 dairiki // Fix comment regarding connecting to SQL server over a unix socket. |