Alertfunction added