Removed the EJS files, documented the code to abstract out the client-side JavaScript, and generally refactored.