Jim*_*Lin 2 javascript jquery html2canvas
我试图使用html2canvas 0.34保存网站的屏幕截图.
但我不知道屏幕截图的保存位置,如何将屏幕截图存储到我的数据库中,或者用新窗口打开图像.
我的代码如下:
<script type="text/javascript">
$('div').html2canvas({
onrendered: function( canvas ) {
var img = canvas.toDataURL();
window.open(img);
}
});
</script>
</head>
<body>
<h1>Testing</h1>
<div>
<img src='http://25.media.tumblr.com/tumblr_mcc5k9YRli1rt6zh0o1_500.jpg'>
</div>
</body></html>
Run Code Online (Sandbox Code Playgroud)
我想将图像的屏幕截图存储到数据库中或在另一个窗口中打开.
非常感谢你.