title: Line drawing not showing on Canvas
body: <p>I am trying to draw a simple line on  but it doesn't work on the page.  I have placed my JavaScript in several places on the html page, but it still doesn't work.</p>
  
  <p>Does anyone know what I did wrong?</p>
  
  <p>Thank you</p>
  
  <p><strong>My JavaScript code:</strong></p>
  
  <pre><code>function drawLine() {
  
  
  var c = document.getElementById("line");
  var draw = c.getContext("2d");
  
  draw.beginPath();
  draw.lineWidth("5");
  draw.strokeStyle("blue");
  draw.moveTo(0, 75);
  draw.lineTo(0, 75);
  draw.stroke();
  
  }
  </code></pre>
  
  <p><strong>My Html code:</strong></p>
  
  <pre><code>&lt;!DOCTYPE html&gt;
  &lt;html lang="eng"&gt;
  &lt;script type="text/javascript" src="vhw.js"&gt;&lt;/script&gt;
  &lt;/head&gt;
  
  &lt;body&gt;
  
  &lt;script type="text/javascript" src="vhw.js"&gt;&lt;/script&gt;
  
  &lt;!-- INTRODUCTION --&gt;
  
  &lt;div&gt;
  
    &lt;h1 class="intro"&gt;
      Line
    &lt;/h1&gt;
  
  &lt;/div&gt;
  
  &lt;!-- LINE CODE --&gt;
  
  &lt;div class="space"&gt;
    &lt;canvas id="line" width="500" height="300" style="border: 2px dotted #990099;    display: block; margin-right: auto; margin-left: auto;" onload="drawLine()"&gt;
    &lt;/canvas&gt;
   &lt;/div&gt;
  &lt;/body&gt;
  
  &lt;/html&gt;
  </code></pre>