1

I have this set up in my 000-default:

<VirtualHost 192.168.1.10:80>
    ServerName live.website.com
    DocumentRoot /var/www/live.website.com
    SetOutputFilter INFLATE;proxy-html;DEFLATE
    CacheEnable mem http://live.website.com/
        MCacheSize 4096
        MCacheMaxObjectCount 1000
        MCacheMaxObjectSize 2048
    CacheDefaultExpire 3600
        CacheMaxExpire 3600
        CacheStoreNoStore On
        CacheStorePrivate On
        CacheIgnoreCacheControl On
        CacheIgnoreNoLastMod On
        MCacheMaxStreamingBuffer 2097152
</VirtualHost>

this page http://live.website.com/index.php only printing : time(), but I see that after 10 seconds the time is re-cached.
Also tried disk, but I get the same results.

Ubuntu + lamp latest.

Thanks

0

A regular PHP script will need to include additional HTTP header information for mod_cache to work. See section "What Can be Cached?" from Apache's Caching Guide.

<?php
header("Cache-Control: must-revalidate, max-age=3600");
header("Vary: Accept-Encoding");
echo time();
| improve this answer | |

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.