Extract mimetype from extension before $_FILES
Pass the full $_FILES array after upload()
Updated docblocks