File size: 11.87Kb
<?xml version="1.0" encoding="iso-8859-1"?>
<!DOCTYPE html
PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<title>File Source for config.inc.php</title>
<link rel="stylesheet" href="../media/stylesheet.css" />
<!-- template designed by Julien Damon based on PHPEdit's generated templates, and tweaked by Greg Beaver -->
<body bgcolor="#ffffff" ><h1 align="center">Source for file config.inc.php</h1>
<p>Documentation is available at <a href="../AlberT-cache/_config_inc_php.html">config.inc.php</a></p>
<pre><a name="a1"></a><br />1 <strong><?php</strong><a name="a2"></a><br />2 <font color="#009999">/**</font><a name="a3"></a><br />3 <font color="#009999"> * AlberT-cache</font><a name="a4"></a><br />4 <font color="#009999"> * fast and portable full-page caching system</font><a name="a5"></a><br />5 <font color="#009999"> *</font><a name="a6"></a><br />6 <font color="#009999"> *</font><a name="a7"></a><br />7 <font color="#009999"> * You have simply to include the main cache filename</font><a name="a8"></a><br />8 <font color="#009999"> * </font><em><font color="#0099FF">{@link AlberT-cache.inc.php }</font></em><font color="#009999">, eventually overwriting some</font><a name="a9"></a><br />9 <font color="#009999"> * configuration variables just <b>before</b> inclusion</font><a name="a10"></a><br />10 <font color="#009999"> *</font><a name="a11"></a><br />11 <font color="#009999"> *</font><font color="#009999"> </font><strong><font color = "#0099FF">@copyright</font></strong><font color="#009999"> Copyleft &copy; Emiliano Gabrielli</font><a name="a12"></a><br />12 <font color="#009999"> *</font><font color="#009999"> </font><strong><font color = "#0099FF">@license</font></strong><font color="#009999"> http://opensource.org/licenses/gpl-license.php GNU Public License</font><a name="a13"></a><br />13 <font color="#009999"> *</font><font color="#009999"> </font><strong><font color = "#0099FF">@author</font></strong><font color="#009999"> Emiliano Gabrielli <[email protected]></font><a name="a14"></a><br />14 <font color="#009999"> *</font><font color="#009999"> </font><strong><font color = "#0099FF">@version</font></strong><font color="#009999"> $Id: config.inc.php,v 1.6 2004/12/14 17:38:07 albert Exp $</font><a name="a15"></a><br />15 <font color="#009999"> *</font><font color="#009999"> </font><strong><font color = "#0099FF">@package</font></strong><font color="#009999"> AlberT-cache</font><a name="a16"></a><br />16 <font color="#009999"> */</font><a name="a17"></a><br />17 <a name="a18"></a><br />18 <font color="blue">/**#@+</font color="blue"><a name="a19"></a><br />19 <font color="blue"> * <p></font color="blue"><a name="a20"></a><br />20 <font color="blue"> * This configuration variable may be overwritten in every page.</font color="blue"><a name="a21"></a><br />21 <font color="blue"> */</font color="blue"><a name="a22"></a><br />22 <a name="a23"></a><br />23 <font color="#009999">/**</font><a name="a24"></a><br />24 <font color="#009999"> * Whether or not to use GZIP, defaults to 1.</font><a name="a25"></a><br />25 <font color="#009999"> *</font><font color="#009999"> </font><strong><font color = "#0099FF">@global </font></strong><font color="#009999"></font><em>bool </em><font color="#009999"></font><strong>$CACHE_GZIP </strong><a name="a26"></a><br />26 <font color="#009999"> */</font><a name="a27"></a><br />27 <font color="blue">if</font> <strong>(</strong><strong>!</strong>isset<strong>(</strong><strong>$CACHE_GZIP</strong><strong>)</strong><strong>)</strong><a name="a28"></a><br />28 <strong>$CACHE_GZIP</strong> = 1;<a name="a29"></a><br />29 <a name="a30"></a><br />30 <font color="#009999">/**</font><a name="a31"></a><br />31 <font color="#009999"> * Whether or not to cache POST, defaults to 1.</font><a name="a32"></a><br />32 <font color="#009999"> *</font><font color="#009999"> </font><strong><font color = "#0099FF">@global </font></strong><font color="#009999"></font><em>bool </em><font color="#009999"></font><strong>$CACHE_POST </strong><a name="a33"></a><br />33 <font color="#009999"> */</font><a name="a34"></a><br />34 <font color="blue">if</font> <strong>(</strong><strong>!</strong>isset<strong>(</strong><strong>$CACHE_POST</strong><strong>)</strong><strong>)</strong><a name="a35"></a><br />35 <strong>$CACHE_POST</strong> = 1;<a name="a36"></a><br />36 <a name="a37"></a><br />37 <font color="#009999">/**</font><a name="a38"></a><br />38 <font color="#009999"> * Sets the cache timeout, a value of -1 will disable</font><a name="a39"></a><br />39 <font color="#009999"> * caching, but still allows gzipping.</font><a name="a40"></a><br />40 <font color="#009999"> *</font><a name="a41"></a><br />41 <font color="#009999"> *</font><font color="#009999"> </font><strong><font color = "#0099FF">@global </font></strong><font color="#009999"></font><em>int </em><font color="#009999"></font><strong>$CACHE_TIMEOUT </strong><a name="a42"></a><br />42 <font color="#009999"> */</font><a name="a43"></a><br />43 <font color="blue">if</font> <strong>(</strong><strong>!</strong>isset<strong>(</strong><strong>$CACHE_TIMEOUT</strong><strong>)</strong><strong>)</strong><a name="a44"></a><br />44 <strong>$CACHE_TIMEOUT</strong> = NULL;<a name="a45"></a><br />45 <a name="a46"></a><br />46 <font color="#009999">/**</font><a name="a47"></a><br />47 <font color="#009999"> * Put here additional variables you want the cache</font><a name="a48"></a><br />48 <font color="#009999"> * to be based on.</font><a name="a49"></a><br />49 <font color="#009999"> *</font><a name="a50"></a><br />50 <font color="#009999"> * This is usefull if you want a different page based on the</font><a name="a51"></a><br />51 <font color="#009999"> * value of a particular variable not yet in POST or GET.</font><a name="a52"></a><br />52 <font color="#009999"> * i.e.: your pages are different based on the value of</font><a name="a53"></a><br />53 <font color="#009999"> * $_SESSION['username'].</font><a name="a54"></a><br />54 <font color="#009999"> *</font><a name="a55"></a><br />55 <font color="#009999"> *</font><font color="#009999"> </font><strong><font color = "#0099FF">@global </font></strong><font color="#009999"></font><em>mixed </em><font color="#009999"></font><strong>$CACHE_ALSO </strong><a name="a56"></a><br />56 <font color="#009999"> */</font><a name="a57"></a><br />57 <font color="blue">if</font> <strong>(</strong><strong>!</strong>isset<strong>(</strong><strong>$CACHE_ALSO</strong><strong>)</strong><strong>)</strong><a name="a58"></a><br />58 <strong>$CACHE_ALSO</strong> = NULL;<a name="a59"></a><br />59 <a name="a60"></a><br />60 <strong><font color="blue">/**#@-*/</font></strong><a name="a61"></a><br />61 <a name="a62"></a><br />62 <font color="blue">/**#@+</font color="blue"><a name="a63"></a><br />63 <font color="blue"> * The value of this variable affects the entire site.</font color="blue"><a name="a64"></a><br />64 <font color="blue"> */</font color="blue"><a name="a65"></a><br />65 <a name="a66"></a><br />66 <font color="#009999">/** Turn debugging on/off, defaults to 0.</font><a name="a67"></a><br />67 <font color="#009999"> *</font><font color="#009999"> </font><strong><font color = "#0099FF">@global </font></strong><font color="#009999"></font><em>bool </em><font color="#009999"></font><strong>$CACHE_DEBUG </strong><a name="a68"></a><br />68 <font color="#009999"> */</font><a name="a69"></a><br />69 <strong>$CACHE_DEBUG</strong> = 0;<a name="a70"></a><br />70 <a name="a71"></a><br />71 <font color="#009999">/**</font><a name="a72"></a><br />72 <font color="#009999"> * Turn caching on/off, defaults to 1.</font><a name="a73"></a><br />73 <font color="#009999"> *</font><font color="#009999"> </font><strong><font color = "#0099FF">@global </font></strong><font color="#009999"></font><em>bool </em><font color="#009999"></font><strong>$CACHE_ON </strong><a name="a74"></a><br />74 <font color="#009999"> */</font><a name="a75"></a><br />75 <strong>$CACHE_ON</strong> = 1;<a name="a76"></a><br />76 <a name="a77"></a><br />77 <font color="#009999">/**</font><a name="a78"></a><br />78 <font color="#009999"> * Set the number of seconds the cache will be valid,</font><a name="a79"></a><br />79 <font color="#009999"> * defaults to 900 (15 minutes).</font><a name="a80"></a><br />80 <font color="#009999"> *</font><font color="#009999"> </font><strong><font color = "#0099FF">@global </font></strong><font color="#009999"></font><em>int </em><font color="#009999"></font><strong>$CACHE_EXP </strong><a name="a81"></a><br />81 <font color="#009999"> */</font><a name="a82"></a><br />82 <strong>$CACHE_EXP</strong> = 900;<a name="a83"></a><br />83 <a name="a84"></a><br />84 <font color="#009999">/**</font><a name="a85"></a><br />85 <font color="#009999"> * Set if the hostname has to be appended to the cache filename,</font><a name="a86"></a><br />86 <font color="#009999"> * turn it to 0 in a multi site environment; defaults to 1.</font><a name="a87"></a><br />87 <font color="#009999"> *</font><font color="#009999"> </font><strong><font color = "#0099FF">@global </font></strong><font color="#009999"></font><em>bool </em><font color="#009999"></font><strong>$CACHE_1SITE </strong><a name="a88"></a><br />88 <font color="#009999"> */</font><a name="a89"></a><br />89 <strong>$CACHE_1SITE</strong> = 1;<a name="a90"></a><br />90 <a name="a91"></a><br />91 <font color="#009999">/**</font><a name="a92"></a><br />92 <font color="#009999"> * Set the directory name in which to store cache files.</font><a name="a93"></a><br />93 <font color="#009999"> *</font><font color="#009999"> </font><strong><font color = "#0099FF">@global </font></strong><font color="#009999"></font><em>string </em><font color="#009999"></font><strong>$CACHE_DIR </strong><a name="a94"></a><br />94 <font color="#009999"> */</font><a name="a95"></a><br />95 <strong>$CACHE_DIR</strong> = <a href="http://www.php.net/dirname">dirname</a><strong>(</strong>__FILE__<strong>)</strong>.<font color="#66cccc">'/cache'</font>;<a name="a96"></a><br />96 <a name="a97"></a><br />97 <font color="#009999">/**</font><a name="a98"></a><br />98 <font color="#009999"> * Set the probability the Garbage Collector will be run, defaults to 1 (1%)</font><a name="a99"></a><br />99 <font color="#009999"> *</font><font color="#009999"> </font><strong><font color = "#0099FF">@global </font></strong><font color="#009999"></font><em>bool </em><font color="#009999"></font><strong>$CACHE_GC </strong><a name="a100"></a><br />100 <font color="#009999"> */</font><a name="a101"></a><br />101 <strong>$CACHE_GC</strong> = 1;<a name="a102"></a><br />102 <a name="a103"></a><br />103 <font color="#009999">/**</font><a name="a104"></a><br />104 <font color="#009999"> * Set the 'umask' for the cache files.</font><a name="a105"></a><br />105 <font color="#009999"> * You don't need to change if you don't know what it is :-P</font><a name="a106"></a><br />106 <font color="#009999"> *</font><font color="#009999"> </font><strong><font color = "#0099FF">@global </font></strong><font color="#009999"></font><em>int </em><font color="#009999"></font><strong>$CACHE_UMASK </strong><a name="a107"></a><br />107 <font color="#009999"> */</font><a name="a108"></a><br />108 <strong>$CACHE_UMASK</strong> = 0022;<a name="a109"></a><br />109 <a name="a110"></a><br />110 <strong><font color="blue">/**#@-*/</font></strong><a name="a111"></a><br />111 <strong>?></strong></pre>
<div id="credit">
<hr />
Documentation generated on Wed, 15 Dec 2004 15:11:10 +0100 by <a href="http://www.phpdoc.org" target="_blank">phpDocumentor 1.2.3</a>
</div>
</body>
</html>