I want to display the alert box but for a certain interval. is it possible in javascript or in php?
<p>Right now i am using java-script to display alert message box. it contains ok button if i click the button then only it hides .But my requirement is to display it only for few seconds then it should automatically close and redirect to my page.  </p>

<pre><code>?&gt;
&lt;script type="text/javascript"&gt;
alert("Enter Mandatory fields");document.location='productsegment.php';
&lt;/script&gt;
 &lt;?
</code></pre>
