title: How do I change the location of a canvas element?
body: <p>Can I change the x and y position of a canvas element in Javascript without using CSS?  I cannot seem to find anyone who even asks it on the Internet.</p>
  
  <p>EDIT: Can it be done in HTML?</p>
  
  <pre><code>&lt;html&gt;
  &lt;title&gt;Testing&lt;/title&gt;
      &lt;canvas id="main" width="200" height="200" style="border:1px solid     #c3c3c3;"&gt;
      Error: Browser does not support canvas element.
      &lt;/canvas&gt;
      &lt;script type="text/javascript"&gt;         
          var main = document.getElementById("main");
          var render = main.getContext("2d");
          main.width = 200;
          main.height = 200;
          main.style.left = 100x;
          main.style.top = 100px;
      &lt;/script&gt;
  &lt;/html&gt;
  </code></pre>