Login   Register  
PHP Classes
elePHPant
Icontem

PDF print: Alter a PDF document to make it print when opened

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 (3)   DownloadInstall with Composer Download .zip   Reputation   Support forum (1)   Blog    
Last Updated Ratings Unique User Downloads Download Rankings  
2010-11-16 (3 years ago) RSS 2.0 feedNot enough user ratingsTotal: 1,400 All time: 2,573 This week: 1,428Up
Version License PHP version Categories  
pdf-print 1.0Q Public License (QPL)5.0PHP 5, Files and Folders
Description Author  

This class can be used to alter a PDF document to make it print when opened.

It can open a given PDF file and regenerate it inserting special JavaScript code to make it open the print dialog when it is opened.

The altered PDF file may be saved to a given file or displayed as the current script output.

Innovation Award  
PHP Programming Innovation award nominee
September 2010
Number 3


Prize: One downloadable copy of PhpED Professional
PDF is a format often used as a means to generate documents to be printed on paper of specific dimensions.

When a site serves a PDF document, the browser may open it but usually it is up to the user to tell explicitly the viewer program to print it.

This class provides a more user friendly solution for this problem by altering PDF documents in such way that they contain JavaScript code that makes the viewer program open the print dialog when the document is opened.

Manuel Lemos
Picture of Laurens Ramandt
Name: Laurens Ramandt is available for providing paid consulting. Contact Laurens Ramandt .
Classes: 2 packages by
Country: Belgium Belgium
Age: 22
All time rank: 14219 in Belgium Belgium
Week rank: 1040 Up6 in Belgium Belgium Up
Innovation award
Innovation award
Nominee: 1x

  Files folder image Files  
File Role Description
Plain text file class.pdffile.php Class Main class
Accessible without login Plain text file demo.class.pdffile.php Example Example use
Accessible without login Plain text file class.pdffile-loadContents.php Aux. Modified version of the script to allow direct input of PDF contents, instead of loading from a file.

 Version Control Unique User Downloads Download Rankings  
 0%Total:1,400All time:2,573
 This week:0This week:1,428Up