I have a question which I see from googling has been discussed at length.. but I want to know what you would recommend based on our particular needs. I want to be on the right track before I find out a-week-of-work later that I chose the wrong tool (a tool which works, but whose peculiarity, in the end, would rule it out for our project).
I read some good threads on Stack Overflow already on this topic.. but they have people making recommendations all over the map.. as I would expect - generally, our needs and experiences are all over the map. And again, here I want to know what you would recommend given our specific situation.
We have a dynamic HTML page that displays 30 "address labels" within the dimensions of one single US-letter-size document. We want the user to be able to print the single letter-sized page and have the content line up perfectly (as it does in the browser) for the Avery address label (printed) sticker paper which they will use to then peel the 30 stickers and affix to physical product. The HTML page is ~ 200k worth of HTML (divs and tables), text, gifs, jpgs, a barcode PNG graphic, and heavy use of exacting CSS - CSS2 as well as a touch of CSS3 (CSS3 property transform), i.e. this:
/* --- for firefox, safari, chrome, etc. --- */
-webkit-transform: rotate(90deg);
-moz-transform: rotate(90deg);
/* --- for ie --- */
filter: progid:DXImageTransform.Microsoft.BasicImage(rotation=1);
...which I use to rotate (90 degrees) a barcode which I grab off of this site/service: http://www.barcodesinc.com/generator/index.php
We could drop that barcode PNG/service only if I could easily replace it with another... and the barcode must be rotated 90 degrees - to thus fit in its tiny (vertically-oriented) alloted slot on each of the 30 "address label cells".
My PHP skills are not super strong yet.. but I am willing to do whatever it takes to pull any solution together. In case you have any familiarity with any PDF generation tools that you feel would fit the need here, then please advise!
If you're looking for something like Prince XML but without the expense, I would try DocRaptor.com. It's an online pdf generator that converts from HTML. I used the free plan and it was pretty easy.
Good luck!
Nate
My usual suggestion for such things is wkhtmltopdf. Your webkit-transform thing should still work, as will anything else that works across web kit browsers.
Fair Warning: I haven't used it myself.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With