我想实现我的代码的jQuery filedownload但我使用本地系统作为我的文件系统来下载文件有人可以帮助我在这方面,我是新来的jQuery或预期它不工作而是提供一个工作代码。jQuery的filedownload无法下载
<%@页语言= “Java” 的的contentType = “text/html的;字符集= ISO-8859-1” 的pageEncoding = “ISO-8859-1” %>
$(document).on("click", "a.fileDownloadSimpleRichExperience", function() {
$.fileDownload($(this).prop('href'), {
preparingMessageHtml: "We are preparing your report, please wait...",
failMessageHtml: "There was a problem generating your report, please try again."
});
return false; //this is critical to stop the click event which will trigger a normal file download!
});
</script>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
<title>Insert title here</title>
</head>
<body>
<a href="E://Download/Anshuman.txt" class="fileDownloadSimpleRichExperience">Download</a>
</body>
</html>
控制台上的任何错误消息? –