I am working on a project using Spring 3.0 and Hibernate 3.x which requires the conversion of HTML pages (either from URL or File) to images. This can be done through command line tools or java libraries. Opensource is ok. HTML 5 and CSS 3.0 support is important.
Asked
Active
Viewed 4,452 times
2
-
So you want a screengrab of the rendered html page? – Grim... Feb 21 '12 at 11:31
-
http://stackoverflow.com/questions/1963900/php-library-for-converting-html-to-image – Pheonix Feb 21 '12 at 11:32
-
possible duplicate of ["Convert web page to image"](http://stackoverflow.com/questions/968201/convert-web-page-to-image) – Ranhiru Jude Cooray Feb 21 '12 at 11:33
-
@Pheonix If you're going to point the OP to another question, probably best if it isn't the duplicate of a duplicate. The original is here: http://stackoverflow.com/questions/713938/how-can-i-generate-a-screenshot-of-a-webpage-using-a-server-side-script – Grim... Feb 21 '12 at 11:34
-
@Grim: that question isn't marked as a duplicate... – Chris Feb 21 '12 at 11:36
-
1See WKHTMLPDF http://code.google.com/p/wkhtmltopdf/ they mention on their site that there is wkimagetopdf for **html to image** conversions, It is almost the best html to pdf conversion library available, I haven't tried it for html to image conversions , you can check it out It might be helpful – Mahmoud Gamal Feb 21 '12 at 11:45
-
@MGA : Thanks MGA! It is very good tool and it is what I was looking for. You could post above comment as answer. – Nandkumar Tekale Feb 27 '12 at 06:38
-
@Nandkumar I reformulated the question. I hope it suits what you were asking for. – James P. Feb 27 '12 at 08:27
1 Answers
4
See WKHTMLPDF.
They mention on their site that there is wkimagetopdf for html to image conversions, It is almost the best html to pdf conversion library available, I haven't tried it for html to image conversions , But I think it worth that you check it out.

Francis Bartkowiak
- 1,374
- 2
- 11
- 28

Mahmoud Gamal
- 78,257
- 17
- 139
- 164