7
In PHP, when we want to close a script, we usually use the function exit().
When we use strings, it terminates the execution of script and print that string.
Example:
exit('Stack Overflow'); // Stack Overflow
However, if we use a value of the type int, he does not return it;
Example:
exit(0); // Nada é retornado
I imagine that this should serve for some internal functionality of this function.
But after all, what is this whole parameter in exit()?
Just so I understand. This
0to255is because of the values of constantsE_ALL,E_ERRORand etc?– Wallace Maxters
As far as I know, no. This number is you who puts to indicate what you want.
– Maniero