Find out which Javascript function is fired on click