HttpFileCollectionBase files = Request.Files;
//声明一个string存储图片路径
//StringBuilder imgs = new StringBuilder();
List<string> imgs = new List<string>();
for (int i = 0; i < files.Count; i++)
{
HttpPostedFileBase file = files[i];
if (file.ContentLength == 0)
model.ProductThumbnail = null;
}
else
{
string name = file.FileName;
//获取后缀名
string namejpg = Path.GetExtension(name).ToLower();
//对图
//声明一个string存储图片路径
//StringBuilder imgs = new StringBuilder();
List<string> imgs = new List<string>();
for (int i = 0; i < files.Count; i++)
{
HttpPostedFileBase file = files[i];
if (file.ContentLength == 0)
{
model.HeaderThumbnail = null;
model.ProductThumbnail = null;
}
else
{
string name = file.FileName;
//获取后缀名
string namejpg = Path.GetExtension(name).ToLower();
//对图