我编写了一个可以通过公共URL访问的脚本,它运行正常。
当我通过命令行执行脚本时,我只会收到php错误。不明白它为什么不从命令行运行。从命令行或通过浏览器运行脚本时,我需要记住哪些区别?
命令:
[user@domain ~]$ /usr/local/bin/php /home/user/domains/url/public_html/soap/mail.php
错误:
PHP Warning: PHP Startup: Unable to load dynamic library './php_soap.dll' - ./php_soap.dll: cannot open shared object file: No such file or directory in Unknown on line 0
Warning: include(/dbconnect-soap.inc.php): failed to open stream: No such file or directory in /home/user/domains/url/public_html/soap/export.php on line 7
Warning: include(): Failed opening '/dbconnect-soap.inc.php' for inclusion (include_path='.:/usr/local/lib/php') in /home/user/domains/url/public_html/soap/export.php on line 7
Fatal error: Call to a member function query() on a non-object in /home/user/domains/url/public_html/soap/export.php on line 10