JS Cose doesn't run
<p>I'd like to know why my code doesn't work.I'm just trying to change the height attribute from '1000' to '2'
Here's the code:</p>

<pre><code>&lt;!DOCTYPE html&gt;
&lt;html&gt;
&lt;head&gt;
&lt;meta charset="UTF-8"&gt;
&lt;title&gt;Title of the document&lt;/title&gt;
&lt;/head&gt;
&lt;body&gt;
&lt;canvas id="canv" width="1000" height="1000" onclick="click()" onmousemove=""&gt;&lt;/canvas&gt;
&lt;script type="text/javascript"&gt;
function click(){
    var l = document.getElementById("canv");
    l.height = "2";

}
&lt;/script&gt;
&lt;/body&gt;
&lt;/html&gt;
</code></pre>