问题
I am working on a web project where we have to come up with "a cross-browser & printer-friendly solution".
The markup is complex enough but after a few hours I managed to come up with something pretty enough on Chrome using CSS only (with media="print" dedicated stylesheet).
However, after testing it on Firefox (18.0.2) & IE9, I realize that only starting to realize where I got myself into. Firefox only prints the 1st page, and not even properly, it's messy. IE9 prints it all but it looks horrible.
After googling and SOing for some time, I quickly realized that printing web pages using browser's built in print support is rather at an experimental state. Probably fine for neat HTML pages but 90% of the internet is probably not neat HTML pages, anyhow, that's another debate.
So, I am wondering if there is any javascript library that "does the job" ?
I have come across these projects but I'm unsure if this would do the trick:
- http://snapshotmedia.co.uk/blog/jspdf
- http://code.google.com/p/html5shiv/
Thanks in advance
来源:https://stackoverflow.com/questions/14963128/any-good-javascript-library-for-cross-browser-printer-friendly-pages