Tag: jquery upload file plugin

使用jQuery上传文件插件时出错,附加到文件的不需要的字符串(WebKitFormBoundary)

我正在使用这个插件: http : //hayageek.com/docs/jquery-upload-file.php 我用它将文件发送到WCF Rest服务并将其保存在硬盘上。 上传工作正常,但问题是图像,exe等上传损坏。 如果我用文本编辑器打开上传的文件,我可以看到不需要的字符串 开始时: —— WebKitFormBoundaryPUTfurckDMbpBxiw Content-Disposition:form-data; NAME = “文件”; filename =“image.png”内容类型:image / png 最后: —— WebKitFormBoundaryPUTfurckDMbpBxiw– 我的服务代码: Function GetFile(str As Stream, fileName As String, accion As String) As String Try Dim absFileName As String = “C:\inetpub\wwwroot\UploadedComponents\” & fileName Using fs As New FileStream(absFileName, FileMode.Create) str.CopyTo(fs) str.Close() End Using Return […]