I am trying to build a CSRF function that will work for every request. I just generate the token and verified.
now I want to unset the value of $_POST and $_GET if verification failed so that in my next input validation code isset($_POST["name"]) return false.
I can do if(valided_token) checking in every request but its not my purpose.
have any Idea