php - Should I call exit() after calling Location: header?
<p>After calling the redirect function header, should I call exit or not?</p>

<pre><code>&lt;?php // fileA
$urlFailToGoTo = '/formerror.php';

if (sth)
{
   header(sprintf("Location: %s", $urlFailToGoTo));
   exit(); //should I call exit() here? or return?
}

?&gt;
</code></pre>

<p>Thank you</p>
