HackAlert is an intrusion detection script that monitors a web server for unauthorized changes and alerts the webmaster via email. When a hacker gains control of your server and defaces it, you have very little time to respond before users notice it.
When configured appropriately, HackAlert can notify via email within minutes of a malicious hack attack.
When a hacker injects malicious code (like Javascript malware), it is very hard for you to notice it. See the example below. Both web pages look the same, but the page on the right has JS malware injected in it.
If you do not take action as soon as this happens, users will see a screen like this when they visit your page in FF or Chrome. Ouch!
If this happens, you will have to talk to work for many days with Google to get it resolved. And your users will keep seeing this page. Even if you remove the malicious code, visitors to your page will see this.
So, preventing this from happening by reacting quickly to hack attacks is the best way to avoid this.