Possible Duplicate:
Using HTML5/Canvas/Javascript to take screenshots
Is there a way to copy the main graphics context of the HTML page into a canvas?
From Javascript, I’d like to grab a “screen shot” of the current visible HTML page and copy it to a thumbnail image or canvas. (Not from a separate “screen capture” app, but from within the javascript page itself)
You can’t do it.
But If you using google chrome you can write a chrome extension, this give you new javascript functions for capturing images, for example:
For example, you can check the source code Webpage Screenshot Extesnion:
https://chrome.google.com/webstore/detail/webpage-webcam-screenshot/ckibcdccnfeookdmbahgiakhnjcddpki