title: How to take screenshots in python?
body: <p>I've an idea and want to implement it.
  But I'm not sure if it's gonna work. So, wanted to get your inputs.</p>
  
  <pre><code> I would like to take screenshots of a url. 
  </code></pre>
  
  <p>Say, when I open a web-site <code>www.espncricinfo.com</code> , I would like to take screenshot of that page and save locally. This saved image can be converted to <code>GIF</code> later on.
     Can this be achieved through <code>python</code> ?  Any suggestions/inputs to make it ?</p>
  
  <p><strong>Updated</strong></p>
  
  <p>And also is it possible to capture screenshot in <strong>headless-browser</strong> ?</p>
  
  <p>Any possibilities to launch the browser in <code>headless mode</code> (non-GUI) and then take the screenshot of particular area of web-page ?</p>