What is best way to make sure alert box doesnt pop up if an alert is already there?
<p>In javascript, if I have an infinite loop:</p>

<pre><code>setInterval("popalert", 5000)
</code></pre>

<p>Where <code>popalert()</code> simply pops an alert box, what is the best way to make it such that an alert box does not pop up if there is already a single alert box that has not been closed yet?</p>
