The Zend Page Cache component is used to cache the entire output of PHP scripts, without changing the PHP code.
The Zend Page Cache improves PHP application performance by caching the entire output of PHP scripts (HTML, XML, etc.), while still maintaining dynamic capabilities through an elaborate rules system. Rules are configured in the Administration Interface.
Page caching extends the concept of caching files and applies it to pages. Caching by page facilitates the ability to eliminate situations where the same file is used in multiple instances, such as when the same file is used to redirect to several pages.
When to Cache Pages
Pages should be cached when their content is stable and does not require
frequent changes. You can cache any PHP generated output including, HTML,
XML, and images (if the images are generated by PHP, such as graphs and
charts).
Compression should be used to cache content such as HTML, XML and plain
text, but is not recommended for caching binary output.
When Not to Cache Pages
Caching is not recommended for files that have constantly changing output,
such as clocks, timers and database queries.
Compression should not be used for images, PDF files, .exe files, ZIP files
or any other compressed binary formats.
Note:
Zend Page Cache only caches GET and HEAD HTTP requests. To comply with the HTTP RFC, POST requests are never cached.
All cached content is stored in a hashed directory structure on disk. The location is defined by the directive zend_pagecache.save_path.
Web pages that contain sections that continuously change can also be cached. This partial page caching solution can be accomplished by applying the Data Cache API to the portions of code that do not change. Data caching is an intermediate solution to provide a partial performance boost that can sustain the accuracy of changing content.
To find out more about this alternative, go to Data Cache
|
|
|
Related Links: Working with Page Caching |
|
|