Login   Register  
PHP Classes
elePHPant
Icontem

Output Buffering handler: Manage multiple handlers to filter the page output

Recommend this page to a friend!
Stumble It! Stumble It! Bookmark in del.icio.us Bookmark in del.icio.us
  Info   View files View files (2)   DownloadInstall with Composer Download .zip   Reputation   Support forum   Blog    
Last Updated Ratings Unique User Downloads Download Rankings  
2009-06-04 (5 years ago) RSS 2.0 feedStarStarStar 44%Total: 601 All time: 4,757 This week: 1,439Up
Version License PHP version Categories  
obh 1.0GNU General Public Lice...5.0PHP 5, Text processing
Description Author  

This class can be used to manage multiple filters that can filter the output of the current script.

It enables the script output buffering in such way that the output will be filtered by handler code managed by the class.

The class can add multiple handlers that will process the output one after another.

The handler code is treated as PHP code template that is executed to process the output and return the filtered output.

Innovation Award  
PHP Programming Innovation award nominee
January 2008
Number 4


Prize: One book of choice by O'Reilly
PHP is able to capture the output of the scripts and pass it to user-defined callback functions for additional processing.

This allows PHP applications to filter the scripts output in some useful way like, cleaning up redundant data, compressing the output, etc..

However, if you want to apply more than one type of processing, you need to define multiple callback functions and add them with the PHP output buffering functions.

This class can simplify that process by letting applications define simple code lines that are called to process the PHP output without having to setup multiple callback functions.

Manuel Lemos
Picture of Jon Gjengset
Name: Jon Gjengset is available for providing paid consulting. Contact Jon Gjengset .
Classes: 10 packages by
Country: Norway Norway
Age: 25
All time rank: 2301 in Norway Norway
Week rank: 232 Down1 in Norway Norway Equal
Innovation award
Innovation award
Nominee: 3x

  Files folder image Files  
File Role Description
Plain text file OBH.class.php Class Class file
Accessible without login Plain text file OBH.example.php Example Example on how to use the OBH class

 Version Control Reuses Unique User Downloads Download Rankings  
 0%1Total:601All time:4,757
 This week:0This week:1,439Up
 User Ratings  
 
 All time
Utility:66%StarStarStarStar
Consistency:66%StarStarStarStar
Documentation:-
Examples:50%StarStarStar
Tests:-
Videos:-
Overall:44%StarStarStar
Rank:1961