colingoldberg — 2010-11-26T13:08:34-05:00 — #1
I am working with a development team, and we need to be able to generate JPG / PDF output from layered HTML at the size of 2048 x 1536. We would like it to be able to be output at several different sizes for diffferent usages (ie, thumbnail, mobile, print) - the team found this :
They are having a hard time getting it to run on our Red Hat server; is there anything which might get this job done that would run on Red Hat, and doesn't cost $300 ? I am not a PHP coder, but it seems like this functionality should not be dependent on the specific distro of Linux.
Any PHP coders out there with any advice would be most warmly appreciated.
tomb — 2010-11-26T14:26:04-05:00 — #2
Provided it's running X server you should just be able to do
exec('firefox -savepng http://www.whatever.com/');
obviously you'll need to install firefox too.
immerse — 2010-11-27T17:10:45-05:00 — #3
Tom, have you got any links for that functionality? Seems pretty interesting!
I tried Google, but didn't have much luck finding any (official) docs about this...
anthonysterling — 2010-11-27T18:40:17-05:00 — #4
From what I read, you need the Pearl Crescent Page Saver extension to use the -savepng option.
Have you looked at wkhtmltopdf ?
kyberfabrikken — 2010-11-27T19:29:08-05:00 — #5
Search for Firefox and Xvfb. Will give you some hits.
The problem is that you need a full X server running to do this. It's fairly heavy weight.