1

I'm using the code in here to convert an html table to excel:

HTML Table to Excel Javascript

To have styles on the excel, I'm converting all my css styles to inline and it works fine.

Now, I'll be needing to export the same into PDF this time. Any ideas how can this be accomplished?

Community
  • 1
  • 1
lorraine batol
  • 6,001
  • 16
  • 55
  • 114
  • http://www.cloudformatter.com/CSS2Pdf.Demos.Tables has various examples of tables with css both inline as well as in external references – Kevin Brown Nov 10 '14 at 16:27

1 Answers1

0

You could try to use this library: https://parall.ax/products/jspdf

Edit: I just tried it with a table but it didn't work. It seems it's only suitable for very basic HTML.

Thiago Duarte
  • 941
  • 9
  • 21
  • 1
    I also found the built in support for tables in jsdpf very limited and buggy. The [AutoTable plugin](https://github.com/someatoms/jsPDF-AutoTable) makes it a lot easier though. – Simon Bengtsson Jun 18 '15 at 15:21