habib ullah

habib ullah

  • NA
  • 229
  • 14.4k

how we make extensection of images to uplode in mvc

Sep 26 2017 6:00 AM
if (file != null && file.ContentLength > 0)
{
var allowedExtensions = new[] { ".png", ".jpeg", ".jpg" };
file.SaveAs(Server.MapPath("~/images/") + file.FileName);
emp.imag = file.FileName;
}
is not working and not show the extension in the images 

Answers (2)