Prompt user if leaving invite page with unsent invitations 

Here's some javascript that checks to see if the user should have to confirm before leaving the page. My users don't know that there's a second step to do once the name appears in the invite list, which results in many unconfirmed/unsent invitations.