var example = document.getElementById("example"); var ctx = example.getContext('2d'); var pic = new Image(); pic.src = 'URL';
var example = document.getElementById("example"); var ctx = example.getContext('2d'); var pic = new Image(); pic.src = 'URL'; ctx.drawImage(pic, 0, 0);