Printing Accurately Scaled Images From A Browser

5 posts by 3 authors in: Forums > CMS Builder
Last Post: September 9, 2015   (RSS)

By Toledoh - September 6, 2015

Hey Jerry.  Could you use the PDF generation plugin?

Cheers,

Tim (toledoh.com.au)

By gkornbluth - September 7, 2015

Hi Tim,

Thanks for responding.

I tried that but got the same results.

Jerry Kornbluth

The first CMS Builder reference book is now available on-line!







Take advantage of a free 3 month trial subscription, only for CMSB users, at: http://www.thecmsbcookbook.com/trial.php

By gregThomas - September 9, 2015

Hey Jerry,

Tim's suggestion of using create PDF seems like the best solution to me, that way you can ensure the output is always a standard resolution and DPI no matter what browser is used to print the image.

You can set custom flags for the plugin to ensure it always exports using the same resolution and DPI. I set custom flags so that my output would always be 300 DPI and have a resolution of 1024 X 640. You can set these flags on line 16 of the createPDF plugin:

$GLOBALS['CREATEPDF_CUSTOM_SWITCHES']  = ' --page-width 1024px --page-height 640px --dpi 300';  // Set this in your script before called createPDF* functions to pass custom command line switches

Cheers,

Greg

Greg Thomas







PHP Programmer - interactivetools.com

By gkornbluth - September 9, 2015

Thanks Greg,

I'll give it a try and post my results.

Didn't know about the custom flags.

Jerry Kornbluth.

The first CMS Builder reference book is now available on-line!







Take advantage of a free 3 month trial subscription, only for CMSB users, at: http://www.thecmsbcookbook.com/trial.php