Show alert in the browser if PUT request fails

The server now properly responds with error codes if it can't create files.
Finally fixes issue #90.