public string UploadPhoto() // Note: web.config requires maxRequestLength ="1048576" executionTimeout="3600" { GeneralHelpers.AddLogEvent("", "", "ValuesController", "UploadPhoto", "Start", ""); var httpPostedFile = HttpContext.Current.Request; HttpPostedFileBase filebase = new HttpPostedFileWrapper(HttpContext.Current.Request.Files[0]); string fileName = ImageHelpers.UploadAndProcessAvatarImage(filebase); string fullUrl = ImageHelpers.GetAvatarFullUrl(fileName); GeneralHelpers.AddLogEvent("", "", "ValuesController", "UploadPhoto", "Completed", fullUrl); return(fullUrl); }