Will unset($_POST)
remove all POST variables in PHP?
Or do you have to go one by one using unset($_POST['varname'])
?
Will unset($_POST)
remove all POST variables in PHP?
Or do you have to go one by one using unset($_POST['varname'])
?
I would try setting it instead:
$_POST = [];
That said, IMO it's generally a bad practice to directly modify PHP's Super Global arrays, but whatever.
Unsetting might work, I assume you tried it as it's trivial to do. I myself have never tried unsetting it, so who knows it might just work....