Cleaned up the server-side resources.

Server routing and template rendering has been simplified; static resources are
now exposed from / rather than /public; errors returned from the server (AJAX
request) will now be shown correctly in the client.