I'm familiar with generating office documents server-side by including the following at the top of the response:
<%
Response.Buffer = True
Response.ContentType = "application/msword"
Response.AddHeader "content-disposition", "inline; filename = ASP_Word_Doc.doc"
%>
I'm currently facing the challenge of doing this purely client-side. 开发者_开发百科I've got an XSL transform that successfully generates valid Word XML. Can anybody give me a pointer to how to reproduce this behaviour using purely client-side javascript?
I've found the document.open method, but that only supports text/html.
Ideally I'd like a cross-browser solution - but IE only would be a satisfactory fall-back
cheers, Ian
To answer one part of your question, Downloadify is a Flash-based JS helper library that lets you generate any kind of file for download locally.
精彩评论