PHP Classes

PHP Print: Abstraction for printing documents

Recommend this page to a friend!
  Info   View files Example   Screenshots Screenshots   View files View files (4)   DownloadInstall with Composer Download .zip   Reputation   Support forum (8)   Blog    
Ratings Unique User Downloads Download Rankings
StarStarStarStar 61%Total: 15,608 This week: 2All time: 54 This week: 41Up
Version License PHP version Categories
php_print_lpr 1.0.0GNU Lesser Genera...5PHP 5, Printing


This package provides an abstract interface for printing documents.

Currently the package includes one implemented class that allows printing of basic text or preformatted (.prn) document files using the LPR protocol

The data to be sent to the printer can be either a filename or a string.

The driver interface provides hooks in the code to allow development of printer filters (drivers). Other driver classes can be developed to implement custom printer filtering like for instance to send documents to Postscript printers.


Printing page setting dynamically
Need to print page setting options dynamically

Innovation Award
PHP Programming Innovation award nominee
September 2005
Number 5

Prize: One copy of DWeb Pro Lifetime License
Many Web applications need to provide means to print documents that they generate.

Printing documents is a task that can be implemented in ways that depend on the device into which the documents are printed, and also on the operating system in use.

This class provides an abstract interface that separates the generation of document printing data from the actual printing process. Many drivers can be developed to support different types of printing processes.

Manuel Lemos
Picture of Mick Sear
Name: Mick Sear is available for providing paid consulting. Contact Mick Sear .
Classes: 8 packages by
Country: United Kingdom
Age: 50
All time rank: 372 in United Kingdom
Week rank: 25 Up2 in United Kingdom Equal
Innovation award
Innovation award
Nominee: 2x

Winner: 1x

  • example.gif
  Files folder image Files  
File Role Description
Plain text file lpr_example.php Example Example of use
Plain text file PrintSend.php Class Abstract Class
Plain text file PrintSendLPR.php Class LPR class
Plain text file test.txt Data Test data file

 Version Control Unique User Downloads Download Rankings  
This week:2
All time:54
This week:41Up
User Ratings User Comments (4)
 All time
6 years ago (Infonet)
good game
6 years ago (muabshir)
This works very well and was very easy to implement
10 years ago (Billy Hallman)
Lite code for good function
14 years ago (Serge IZOARD)