I believe it is recommended to use filter_var nowadays. Apart from XSS type of filtering it's also great to check for example an emailaddress, instead of using a regex. See all types of filters.
GitHub Campus Expert🚩 || Beta MLSA ||
Promoting & sharing educative tips & resources from Devs💻 and for Devs💻| Buy me a ☕
https://www.buymeacoffee.com/qbentil
GitHub Campus Expert🚩 || Beta MLSA ||
Promoting & sharing educative tips & resources from Devs💻 and for Devs💻| Buy me a ☕
https://www.buymeacoffee.com/qbentil
I believe it is recommended to use filter_var nowadays. Apart from XSS type of filtering it's also great to check for example an emailaddress, instead of using a regex. See all types of filters.
I do agree, also using filter_input() and filter_input_array() should be preferred to using superglobals.
Thanks for the input
That's imperative to do.
Thanks for adding👏