Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
如何读取扩展名中的文件Asterisk 13和OpenWRT 17.04?例如,我想将文件中的文本重新发送到聊天。ReadFile()不幸的是,存储库中缺少该应用程序。
Asterisk 13
OpenWRT 17.04
ReadFile()
ReadFile 已被弃用。根据文档,您应该改用 FILE 函数。
文件函数语法:
Set(varname=${FILE(file,0,length)})
而不是 Readfile 应用程序:
ReadFile(varname=file,[length])
来源:Asterisk 项目文档
你有2个选择
1) 使用 AGI 和 bash(php, python etc) 脚本来读取您需要的部分文件。
2)构建更多模块(参见openwrt doc,很简单)。