Changed url back to localhost and removed some debugging print statements.