0
I have a script that creates an image of a div
using html2canvas and would like to know if there is any way to change the whidth
and the height
of that image.
<div id="MinhaDiv">Conteúdo a ser renderizado</div>
<input id="Gerador" type="button" value="Gerar Imagem"/>
<div id="IMGfinal" ></div>
<script>
$(document).ready(function(){
var element = $("#MinhaDiv");
$("#Gerador").on('click', function () {
html2canvas(element, {
onrendered: function (canvas) {
$("#IMGfinal").append(canvas);
}
});
});
</script>
Thanks, it helped me a lot. I was using the properties the wrong way, but now everything works top;
– Paulo Henrique N matos