title: Add alert below previous alert with position absolute?
body: <p>I want to display alerts, and if one already exists, display the new one under that one. And so on.</p>
  
  <p>This is what I'm doing right now, which doesn't exactly work as I want it to as it only works for 2 alerts or less shown at the same time.</p>
  
  <pre><code>var alert = document.createElement("div");
  
  alert.className = "alert alert-" + type + " alert-dismissable";
  alert.innerHTML = msg;
  
  document.getElementsByTagName("body")[0].appendChild(alert);
  
  var currentAlerts = document.getElementsByClassName("alert");
  if(currentAlerts.length &gt; 0) {
      for(var i = 1; i &lt;= currentAlerts.length; i++) {
          if(currentAlerts[i] != undefined) {
              alert.style.top += ((i * 1.5) * currentAlerts[i].offsetHeight) + "px";
          }
      }
  }
  </code></pre>
  
  <p>How can I make the next alert be positioned right below the previous one with a spacing between them of 10 px?</p>