Used jquery to create events on html elements