让PHP在Linux上读取.doc文件 [英] Getting PHP to read .doc files on Linux

查看:162
本文介绍了让PHP在Linux上读取.doc文件的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我试图读取一个.doc文件到数据库,以便我可以索引它的内容。有一个简单的方法,PHP上的Linux上阅读.doc文件?没有可能将.doc文件转换为rtf,pdf或其他易于阅读的开放格式?

I'm trying to read a .doc file into a database so that I can index it's contents. Is there an easy way for PHP on Linux to read .doc files? Failing that is it possible to convert .doc files to rtf, pdf or some other 'open' format that is easy to read?

注意,我不感兴趣。 docx文件。

Note, I am not interested in .docx files.

推荐答案

似乎有一个用于访问Word文档的库,但不确定如何从PHP访问它。我认为最好的解决方案是从PHP调用他们的 wv命令

There seems to be a library for accessing Word documents but not sure how to access it from PHP. I think the best solution would be to call their wv command from PHP.

这篇关于让PHP在Linux上读取.doc文件的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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