Added functionality for file upload.