问题背景:项目开发测试阶段出现该问题. 复现:开发调试过程中一直没有问题,本地下载excel.Word.pdf 都完美,但是在服务部署到服务器之后,测试环境的chrome就总是下载失败,提示网络错误. . 这时候追踪问题,本地测试时发现每次下载都会有问题警示:Resource interpreted as Document but transferred with MIME type application/octet-stream, 各种百度,大多数都是说修改content-type,但是不管
Forbidden (403) CSRF verification failed. Request aborted. You are seeing this message because this site requires a CSRF cookie when submitting forms. This cookie is required for security reasons, to ensure that your browser is not being hijacked by
参考链接 https://stackoverflow.com/questions/6773866/download-file-and-automatically-save-it-to-folder public class MyWebBrowser : WebBrowser { /// <summary> /// The URLMON library contains this function, URLDownloadToFile, which is a way /// to downloa