Made the example feature-complete and moved all POST data handling from client to server.