What is Cross-Site Scripting (XSS) and how could it be used?

Cross-site scripting (XSS) is one of the most common threats open to attack in modern web applications today. According to some reports, this could be as high as 47.9% of all sites being susceptible [1] [3] and is ranked as the 3rd highest issue with web applications by OWASP a research group into web vulnerabilities.[…]