Bug fixes to the file upload stuff.
Some new classes.