Implemented progress bar for uploading an image.