What is "sanitize"
Sanitization is the process of removing specific characters from a value, which are not required or desired by the user or application.
Generally this process aims to ensure that the integrity of the application.
Among the most common cleaning tasks we can find:
Leave only lower case letters:
LEtras minúsCulas → letras minúsculasExchange accented letters for the same letter without accent:
LEtras acêntuádas → LEtras acentuadasReplace spaces with a hyphen (common in URL Slugs):
URL Slug → URL-SlugRemove special characters:
#Isto é uma **afirmação**! → Isto é uma afirmaçãoLeave only numbers:
+44 0800 700 200 → 440800700200