updating html reference to events array