News Feed
Sections




News Archive
Looking for more information on how to do PHP the right way? Check out PHP: The Right Way

Cesarodas.com:
gCache Helping PHP to work faster
June 28, 2007 @ 11:26:00

On Cesarodas.com, Saddor as created a simple class to help with caching information in a PHP application - specifically when it comes to capturing output (like HTML generated for the page).

Usually we need to find a way to help php to reduce the number of query to a database, because as a friend told me: "Most of time php is awaiting for a database to response". And that is wasted resource (time, processor, main memory). The developer need to find a way to store some pages until it changes or something like that. There are many cache classes over there, but exist many problems, I will focus on two problems. Implementation and concurrence.

His gCache class uses capture/endcapture methods to define where the content starts and ends and, once the information is stored, checks with a valid method and echoes the content if it's been cached. An example of the class in action is also included.

2 comments voice your opinion now!
cache output capture class cache output capture class


blog comments powered by Disqus

Similar Posts

Project: Patchwork-Doc - JSON Formatted Output of PHP variables

PHPClasses.org: A PHP killer feature - Streams abstraction

Kae Verens' Blog: Serving files through a script

NetTuts.com: Create WordPress Plugins with OOP Techniques

Richard Heyes' Blog: Reading a specific line in a file


Community Events

Don't see your event here?
Let us know!


security release community voicesoftheelephpant language extension laravel series library laravel5 introduction podcast opinion symfony api unittest interview framework threedevsandamaybe version

All content copyright, 2015 PHPDeveloper.org :: info@phpdeveloper.org - Powered by the Solar PHP Framework