What are the causes of HTTP 404 errors?

Please tell me what is cross-site scripting and how is it harmful for your application?