我搜索了很长一段时间以找到 Coldfusion 解析 OFX 文件的示例,但找不到任何东西。任何人都可以帮助提供一些示例代码或指出正确的方向吗?
问问题
405 次
2 回答
2
可能会尝试开源 OFX4J java lib。
于 2019-01-02T01:08:06.197 回答
-1
我已经构建了一个库,可以解析出 ZIP XML 文件,例如.docx
. 您可能想尝试一下。
先看看能不能解压和读取文件
string function extractDocx(required string pathToDocX) {
cfzip(action="read", file=arguments.pathToDocx, entrypath="word\document.xml", variable="this.xmlString");
this.xmlPara = xmlparse(this.xmlString).document.body;
return ReadNode(this.xmlPara);
}
然后,结果需要转到递归解析器。看:
https://coldfusion.adobe.com/2018/11/extracting-text-html-out-word-docx-files/ https://github.com/jmohler1970/WordExtractor_demo https://github.com/jmohler1970/WordExtractor
于 2019-01-01T21:17:19.100 回答