62,072
社区成员
发帖
与我相关
我的任务
分享
<html xmlns="http://www.w3.org/1999/xhtml">
<head runat="server">
<title></title>
<script src="../../js/jquery-1.6.3.min.js" type="text/javascript"></script>
</head>
<body>
<form id="form1" runat="server" action="../ashx/saveData.ashx" target="hiddenForm" enctype="multipart/form-data" method="post">
<input type="file" name="UploadFile"/>
<input type="submit" value="上传">
<iframe name="hiddenForm" style="display:none;" ></iframe>
</form>
</body>
</html>
ashx 文件里面获取文件
HttpPostFile UploadFile=context.Request.Files["UploadFile"];
下面在进行文件IO就OK了。