How to Gammu sendsms php shell_exec windows 7 and xampp?

删除回忆录丶 提交于 2019-12-02 03:36:42

问题


I have already installed XAMPP latest version and installed gammu.

In terminal I can send sms or identify my cellphone, but if i try the same command on php shell_exec or exec there is something wrong.

The command:

"C:\Program Files\gammu\bin\gammu.exe" --sendsms TEXT 06706177529 -text "halooo"
This works.

The command in php:

$a = shell_exec('"C:\Program Files\gammu\bin\gammu.exe" --sendsms TEXT 06706177529 -text "halooo"');

This write to me:

Warning: No configuration file found! Warning: No configuration read, using builtin defaults! Error opening device, it doesn't exist.

What can be wrong?


回答1:


Actually my solution wasnt bad. I just had to copy the configuration files of gammu to the php wich hast the code. So the config needs to be in the same folder with the php.



来源:https://stackoverflow.com/questions/20676718/how-to-gammu-sendsms-php-shell-exec-windows-7-and-xampp

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!