In PHP, when we want to terminate a script, we usually use the exit
function.
When we use strings, it terminates the script and prints this string .
Example:
exit('Stack Overflow'); // Stack Overflow
However, if we use a value of type int
, it does not return it;
Example:
exit(0); // Nada é retornado
I imagine this should serve some internal functionality of this function.
But what is the purpose of this integer parameter in exit
?