title: What happens if a user exits the browser or changes page before an AJAX request is over
body: <p>I am calling a php script over ajax to do some database maintenance. If the user closes the page, hits back, or clicks a link, will the php script be fully executed? Is there a way to do it?</p>
  
  <p>Maybe if the php script called the <code>exec()</code> method or something similar, which would in turn call a script via the console as such:</p>
  
  <pre><code>$ php /var/www/httpdocs/maintenance.php
  </code></pre>
  
  <p>?</p>