How can I generate a screenshot of a webpage using a server-side script?

Colargol picture Colargol · Apr 3, 2009 · Viewed 20.4k times · Source

I need a server-side script (PHP, Python) to capture a webpage to a PNG, JPG, Tiff, GIF image and resize them to a thumbnail.

What is the best way to accomplish this?

See also:

Answer

Can Berk Güder picture Can Berk Güder · Apr 3, 2009

You can probably write something similar to webkit2png, unless your server already runs Mac OS X.

UPDATE: I just saw the link to its Linux equivalent: khtml2png

See also: