6

I would like to generate a report file from a view&template in django. Preferred file formats would be OpenOffice/ODF or PDF.

What is the best way to do this?

I do want to reuse the page layout defined in the template, possibly by redefining some blocks in a derived template.

Ideally, the report should be inserted into an existing template file so I can provide the overall page layout, headers and footer in the generated output format.

2
  • Dupe of stackoverflow.com/questions/177799/…. Commented Oct 22, 2008 at 9:57
  • Not quite a duplicate, as I am looking for a way to re-use my django templates. Thanks for the hint though. Commented Oct 22, 2008 at 15:01

2 Answers 2

4

pisa/xhtml2pdf should get you covered for PDF. It even includes an example Django project.

Sign up to request clarification or add additional context in comments.

Comments

3

Try ReportLab for PDF output:

http://www.reportlab.org/

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.