title: I'm Unable to Clear the Form
body: <pre><code>&lt;!DOCTYPE html&gt;
  &lt;html&gt;
  &lt;head&gt;
      &lt;title&gt;Onreset-3&lt;/title&gt;
  &lt;/head&gt;
  &lt;body&gt;
      &lt;form&gt;
          Username: &lt;input type="text" class="abc"&gt;&lt;br&gt;&lt;br&gt;
          Password: &lt;input type="password" class="abc"&gt;&lt;br&gt;&lt;br&gt;
      &lt;/form&gt;
      &lt;input type="button" onclick="reset()" value="Clear"&gt;
      &lt;script&gt;
          function reset()
          {
              var a = document.getElementsByClassName('abc');
              a.value = "";
          }
      &lt;/script&gt;
  &lt;/body&gt;
  &lt;/html&gt;
  </code></pre>
  
  <p>I am unable to clear the username and password in the above form. I have been trying using id's but no use</p>