views:

570

answers:

2

I am looking for an open source template engine in the style of smarty or dwoo (preferable dwoo due to its inheritance features) that can be used to create pdf files instead of html. I am not talking about just a pdf library that allows the creation of the function/method calls, but something that allows to create the page content in a similar way as the above mentioned template engines.

Has anybody seen something like that, or another idea that would allow me to do something similar?

Thanks.

+1  A: 

Have you considered using your preferred HTML template engine and then passing the results to an HTML to PDF library Say something like http://www.rustyparts.com/pdf.php

Rob Booth
I have considered this after your suggestion. However, I am afraid this solution is not what I am looking for, since it would never be used as html. However, I will have some more thoughts about it, thanks for the answer anyway.
txwikinger
Shouldn't matter if you are ever going to use it as HTML or not. If you can build what you want to see in the PDF in HTML easier, quicker, cheaper, better, stronger, faster (sorry channeled the 6 million dollar man there for a second). Then why not use that solution? Seems like a win win to me, and this is the solution that I'll be using in my own project even though the PDF data will never be displayed as HTML.
Rob Booth
A: 

I have decided to extend an existing template system to also create pdf output.

txwikinger