title: setTimeout() is not waiting
body: <p>I am trying to make a seconds countdown with Javascript.</p>
  
  <p>Here is my HTML</p>
  
  <pre><code>&lt;div id="ban_container" class="error center"&gt;Please wait
          &lt;span id="ban_countdown" style="font-weight:bold"&gt;
          45&lt;/span&gt;
          seconds before trying again
  &lt;/div&gt;
  </code></pre>
  
  <p>And my JS:</p>
  
  <pre><code>&lt;script type="text/javascript"&gt;
      var seconds = &lt;?php echo $user-&gt;getBlockExpiryRemaining(); ?&gt;;
  
      function countdown(element) {
          var el = document.getElementById(element);
  
          if (seconds === 0) {
              document.getElementById("ban_container").innerHTML = "done";
              return;
          }
          else {
              el.innerHTML = seconds;
              seconds--;
              setTimeout(countdown(element), 1000);
          }
      }
  
      countdown('ban_countdown');
  &lt;/script&gt;
  </code></pre>
  
  <p>However for some reason, it is not waiting the timeout time, but instead executes <code>countdown</code> right away so that when I refresh the page it just displays "done" right away. I know it is actually being executed multiple times because if I do <code>innerHTML += seconds + " ";</code> it counts down from 45. Why is the timeout being bypassed?</p>