title: Uncaught TypeError: object is not a function onclick
body: <p>I receive the error "Uncaught TypeError: object is not a function" when clicking on a button in my webpage.</p>
  
  <p>The button code is:</p>
  
  <p><code>&lt;button id="addUser" name="addUser" onclick="addUser()"&gt; Add User &lt;/button&gt;</code></p>
  
  <p>The code for function addUser is </p>
  
  <pre><code>function addUser() {
  
      userValue = document.getElementById("userForAdmin");
      passValue = document.getElementById("passForAdmin");
      console.log(userValue.value);
      console.log(passValue.value);
  }
  </code></pre>
  
  <p>Can anyone point out my error? My guess is its likely a basic mistake.</p>