views:

371

answers:

5

I need to get fullscreen shot of website by URL, is there any PHP programs for that or services, if not, is there any Java programs for that purpose?

+2  A: 

Litmus is a great online resource for this kind of thing; you can submit a URL and have it take full-page screenshots on the latest browsers. If you get a paid subscription or use it on weekends, you'll have access to test on all 22 of its browsers instead of just the most recent. I use this website all the time, I think it's phenomenal.

BrowserShots is also great, and it supports tons more browsers, but in my experience it's a lot slower too. It's good to use if you need to test some browser Litmus doesn't, though.

Twisol
I didn't mean that I need to test webpages on different browsers, but rather I need to get screenshots fast from given urls. Is there any open source/free application for that, it really doesn'y have to be php or java, just free software that works...
newbie
I guess I'm not understanding the difference. You could still use Litmus or Browsershots for that same thing, just run the test for one browser.
Twisol
+3  A: 

You need to have a special version of a browser to "render" the page after it's processed by PHP or Java.

You'll most-likely need to set up some custom automation scripts to hit a URL after you ping a server running windows, OSX or a Linux window manager.

There are services out there which will do screen shots for you.

http://www.browsercam.com

http://webthumb.bluga.net/home

to name a few.

null
A: 

You can also do it yourself if you had a dedicated server. The idea is to launch a X Server and a browser in fullscreen mode, to take a shot, and save it into an image file.

Depending of your utilisation (occasional or intensive), you can adapt the process (i.e. not killing X everytime, etc...) to make it faster.

swordofpain
+4  A: 

There are plenty of ways:

  1. Use http://khtml2png.sourceforge.net/index.php?page=faq

  2. Use webkit engine with some bindings for it: http://www.blogs.uni-osnabrueck.de/rotapken/2008/12/03/create-screenshots-of-a-web-page-using-python-and-qtwebkit/

  3. Use mozilla engine in batch mode: http://www.chimeric.de/blog/2007/1018%5Fautomated%5Fscreenshots%5Fusing%5Fbash%5Ffirefox%5Fand%5Fimagemagick

Kane
wow, #2 is awesome! Going to have to remember that for the future.
snicker
A: 

It's not clear from the question whether you're looking to do this programatically or manually. If manually: there is a great plug-in for Firefox called Abduction! that renders a page as an image. Otherwise, Kane's answers have it pretty much covered.

Rob