Don't try to sanitize input. Escape output.
Why you should escape output correctly, but generally not sanitize user input.
Source: benhoyt.com
Stay updated with breaking news from Both Stack Exchange. Get real-time updates on events, politics, business, and more. Visit us for reliable news and exclusive interviews.
Why you should escape output correctly, but generally not sanitize user input.