add image upload function for app.