【发布时间】:2013-10-02 08:42:18
【问题描述】:
我正在尝试使用 C# 开发 Web 移动应用程序。它只是一个简单的上传图片模块,并获取它的exif。该应用程序在 PC 上的普通浏览器上运行良好。可以上传文件,可以读取exif。
但是,在大多数移动浏览器上进行测试时,会抛出此异常:'Could not find a part of the path 'c:\inetpub\wwwroot\Temp\1.jpg'。
这是 .aspx 文件中的行
<input id="imgUpload" type="file" runat="server" />
以及 .aspx.cs 文件中的行
string filename = myProfile.ID.ToString() + ".jpg";
string physiclPath = HttpContext.Current.Server.MapPath("..\\..\\Temp\\");
imgUpload.PostedFile.SaveAs(physiclPath + filename);
Response.Write("File uploaded successfully!");
对于网络移动上传有什么重要的我想念的吗?
【问题讨论】: