在没有安装 MS Word 的情况下将 html 导出到 Word 的最佳方法? [英] Best way to export html to Word without having MS Word installed?

查看:23
本文介绍了在没有安装 MS Word 的情况下将 html 导出到 Word 的最佳方法?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

有没有办法在不安装 Microsoft Word 的情况下将简单的 HTML 页面导出到 Word(.doc 格式,而不是 .docx)?

Is there a way to export a simple HTML page to Word (.doc format, not .docx) without having Microsoft Word installed?

推荐答案

如果你说的只有简单的HTML页面,可以用Word打开.

If you have only simple HTML pages as you said, it can be opened with Word.

否则,有一些库可以做到这一点,但我没有使用它们的经验.

Otherwise, there are some libraries which can do this, but I don't have experience with them.

我的最后一个想法是,如果您使用的是 ASP.NET,请尝试将 application/msword 添加到标题中,然后您可以将其另存为 Word 文档(它不会是真正的 Worddoc,只有重命名为 doc 的 HTML 才能打开).

My last idea is that if you are using ASP.NET, try to add application/msword to the header and you can save it as a Word document (it won't be a real Word doc, only an HTML renamed to doc to be able to open).

这篇关于在没有安装 MS Word 的情况下将 html 导出到 Word 的最佳方法?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆