added template for bind events