https://issues.apache.org/bugzilla/show_bug.cgi?id=48364
Summary: PHP-generated pages are not cached in spite of
pertinent header entries
Product: Apache httpd-2
Version: 2.2.13
Platform: Sun
OS/Version: Solaris
Status: NEW
Severity: normal
Priority: P2
Component: mod_cache
AssignedTo: [email protected]
ReportedBy: [email protected]
Whereas Apache 2.2.x mod_cache (with mod_disk_cache) works with both static
files and CGI scripts (including such with #!/path/to/php-cgi), I have never
been able to cache output of PHP (5.2.x) scripts handled by the handler+action
method. Of course, I added pertinent header entries (Last-Modified, Expires,
Cache-Control) by the PHP function header(), which were correct as shown by
network sniffing and caused the browser cache to behave as expected. But no
cache files appeared in the CacheRoot directory. Also directives
CacheIgnoreCacheControl On, CacheIgnoreNoLastMod On, CacheStoreNoStore On have
been tried, with no effect.
I did not use mod_php but one CGI and two FastCGI methods (alternatively) in
the following ways (schematic):
# Common
<FilesMatch "\.php$">
SetHandler dophp
</FilesMatch>
Action dophp /phpact
CacheRoot /somedir
CacheEnable disk /
# For CGI:
ScriptAlias /phpact /path/to/php-cgi
# For FastCGI with mod_fastcgi:
ScriptAlias /phpact /path/to/php-fcgi
FastCgiIpcDir /otherdir
FastCgiServer /path/to/php-fcgi further_arguments
# For FastCGI with mod_proxy_fcgi (php-fcgi started separately with -b 54321):
ProxyRequests Off
ProxyPassMatch ^/phpact/(.+)$ fcgi://localhost:54321/$1
Note that PHP as such works perfectly in all three configurations (with
cgi.fix_pathinfo=1 and cgi.force_redirect=1).
I searched the bug database and the documentation but could not find any hint.
--
Configure bugmail: https://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]