Changed jquery query to normal javascript to select canvas.