added basic registration function that adds new emails
resolved lines conflicting in web.js with peter's commit