I recently was notified that a script had been running for 5 days. It was suggested that it might have been one of 3 possible scripts. One had code structured similar to the following:
Edit I had modified the alert message (only) a few days prior to the purported beginning.
<body>
<script type="text/javascript">
alert('Some message');
</script>
<div id="container">
....
The intent was to have the alert viewable before the underlying page loaded.
Could this alert waiting for OK to be pressed in someone’s browser have caused the program to run for days ??
(I did question script time limits, but that was dismissed.) I’m just trying to learn about the process of serving pages. Thanks for looking and answering.
To be clear,
alert()is a client side script. The server completes the processing of the page and sends it to the client. And in your case, the client is the one, which is running now and not the server is suspended.Consider this small PHP Snippet:
The page will load only after
10 secondsof processing by the server and it sends out the fully processed code. So, in anyway, javascriptalertor client side scripting won’t stop server execution.Hope it is clear.