Created
September 24, 2012 02:24
-
-
Save andersonfreitas/3773874 to your computer and use it in GitHub Desktop.
Snippet to load html2canvas in the actual page
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
this.scriptObject=document.createElement('script'); | |
this.scriptObject.type='text/javascript'; | |
this.scriptObject.src='http://html2canvas.hertzen.com/js/html2canvas.js'; | |
var ssc = document.getElementsByTagName('script')[0]; | |
ssc.parentNode.insertBefore(this.scriptObject, ssc); | |
this.scriptObject=document.createElement('script'); | |
this.scriptObject.type='text/javascript'; | |
this.scriptObject.src='http://html2canvas.hertzen.com/js/jquery.plugin.html2canvas.js'; | |
var ssc = document.getElementsByTagName('script')[0]; | |
ssc.parentNode.insertBefore(this.scriptObject, ssc); | |
$(document.body).html2canvas({logging: true, profile: true, useCORS: true }); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment