Cleaned up code, added a bit on the front end, completed request code