The new way of doing it leverages jquery-ui functions.
events.js should eventually be loaded in only the events view. This commit creates #15.