What is NUL or NULL byte and how escaping works with NULL byte?
Can someone please give example?
single quote and double quote is very obvious but i am not clear about NULL byte.
Documentation from PHP.net.
addslashes() returns a string with backslashes before characters that need to be quoted in database queries etc. These characters are single quote ('), double quote ("), backslash () and NUL (the NULL byte).
I tried something like this:
$a = NULL;
$str = " NULL example $a ";
echo addslashes($str);
But i don't see any added slash in output.