php通过baihui网API实现读取word文档并展示

yipeiwu_com6年前PHP代码库

项目中遇到一个小问题,想实现php 如何读取word文档,并将其内容原样显示

可以 使用API 可以看看baihui.com 的写写应用 的API

申请一个 APPKEY 就能使用,你可以看看 ... 对免费版本有限制

比如 excel 支持,可以参考我这个 appkey是我申请的,可以使用吧 ...
保存成本地的一个html文件 打开后直接使用

word 的类似

<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>测试百会格格远程API</title>
</head>
<body>
<form action="http://gege.baihui.com/remotedoc.im?apikey=079c6475174c7a46351260ed35e54ecd&output=editor" target="_self" enctype="multipart/form-data" method="post">
上传文件: <input type="file" name="content" site="38"/>
<input type="hidden" name="filename" value="my.xls,my.xlsx" />
<input type="hidden" name="saveurl" value="http://vai.com" />
<input type="hidden" name="id" value="21012145" />
<input type="hidden" name="format" value="xlsx" />
<input type="hidden" name="persistence" value="true" />
<input type="submit" value="提交" />
</form>
</body>
</html>

以上所述就是本文的全部内容了,希望大家能够喜欢。

相关文章

PHP字符串逆序排列实现方法小结【strrev函数,二分法,循环法,递归法】

本文实例总结了PHP字符串逆序排列实现方法。分享给大家供大家参考,具体如下: 关于字符串的逆序排列,最简单的使用PHP函数strrev()的测试代码如下: header('Conte...

PHP调用Linux命令权限不足问题解决方法

业务背景:  yourcmd为我的linux程序,它对权限要求非常严格,当用php去执行yourcmd程序 系统:CentOS 6.3 apache是php的执行用户 用exe...

解决wincache不支持64位PHP5.5/5.6的问题(提供64位wincache下载) 原创

解决wincache不支持64位PHP5.5/5.6的问题(提供64位wincache下载) 原创

这几天公司有台服务器需要配置,系统是Windows 2008 R2,在IIS上配置环境是64位的PHP5.5,要求支持wincache。原本心想无非就是去wincache的官网下载下来,...

php输出echo、print、print_r、printf、sprintf、var_dump的区别比较

用.net开发已经5年了,最近突然想接触一下。net以外的东西,于是乎就来看看php了。在学习php中首先看看几个输出函数。一、echoecho() 实际上不是一个函数,是php语句,因...

Discuz Uchome ajaxpost小技巧

比如默认submit按钮这样操作:onclick="ajaxpost('formid')";之类的,我们可以先这样。。 onclick="$('__formid').innerText=...