[html]
<%
response.ContentType ="application/vnd.ms-excel"
Response.AddHeader "Content-Disposition", "attachment; filename=1.xls"
%>
[/html]
<%
response.ContentType ="application/vnd.ms-excel"
Response.AddHeader "Content-Disposition", "attachment; filename=1.xls"
%>
[/html]
博客展示了一段HTML代码,通过设置响应头,将内容类型指定为Excel文件类型,并添加下载文件名,实现了在网页中下载Excel文件的功能。
1797

被折叠的 条评论
为什么被折叠?



