截图
来源:互联网 发布:php curl异步抓取 编辑:程序博客网 时间:2024/05/01 03:14
<html> <head> <meta name="layout" content="main"> <meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> <script type="text/javascript" src="http://libs.baidu.com/jquery/1.11.1/jquery.min.js"></script> <script type="text/javascript" src="http://html2canvas.hertzen.com/build/html2canvas.js"></script> <script type="text/javascript" > $(document).ready( function(){ $(".example1").on("click", function(event) { event.preventDefault(); html2canvas(document.body, { allowTaint: true, taintTest: false, onrendered: function(canvas) { canvas.id = "mycanvas"; //document.body.appendChild(canvas); //生成base64图片数据 var dataUrl = canvas.toDataURL(); var newImg = document.createElement("img"); newImg.src = dataUrl; document.body.appendChild(newImg); } }); }); }); </script> </head> <body> Hello! <div class="" style="background-color: #abc;"> 计算机天堂测试html5页面截图 <br>jsjtt.com </div> <textArea id="textArea" col="20" rows="10" ></textArea> <input class="example1" type="button" value="button"> 生成界面如下: </body></html>
阅读全文
0 0
- 截图
- 截图
- 截图
- 截图
- 截图
- 截图
- 截图
- 截图
- 截图
- 截图
- 截图
- 截图
- 截图
- 截图
- 截图
- 截图
- 截图
- 截图
- 微软最完善,百度最小气 看微软阿里百度三大物联网云平台对比
- Struts2框架
- Linux 启动时间优化
- Hibernate(上)
- SpringMVC入门篇(五)POST中文乱码解决
- 截图
- 【Python学习系列十三】Python机器学习库scikit-learn实现逻辑回归
- (1)spring初学-spring简介
- J2EE系列之SpringMVC学习笔记(六)--文件上传
- jQuery中Ajax事件beforesend及各参数含义
- Hibernate(中)
- LeetCode Recover Binary Search Tree
- 91.使用BigDecimal进行精确运算
- python opencv入门(学习笔记no.3)-从摄像头读取视频并显示