0
我正在開發一個使用Codeigniter和Phils RESTserver的API。 它在我的本地機器(mac獅子)上工作得很好,但在我的服務器上(Ubuntu 10.04和PHP 5.3)出現錯誤。PHP和Codeigniter。服務器上的CURL故障,但不是本地機器
Severity: Notice
Message: Use of undefined constant CURLOPT_FAILONERROR - assumed 'CURLOPT_FAILONERROR'
Filename: libraries/REST_Controller.php
Line Number: 717
在行717
$verify = $CI->curl->simple_get($verify_uri, array(), array(CURLOPT_FAILONERROR => FALSE));
什麼是錯在REST_controller.php文件中的行?有什麼我需要升級?
似乎CURLOPT_FAILONERROR常量不能被發現。 也許捲曲模塊未在您的打印系統上安裝/啓用。 我不知道CI的實現,但也許你可以在這裏找到一個提示:http://theserverpages.com/php/manual/en/ref.curl.php –
你可以發佈phpinfo的輸出相關的cURL從你的服務器?最快的方法是從控制檯發出'php -i | grep curl'命令,我認爲 – J0HN
運行你的命令不會給我任何東西。也許CURL沒有安裝? php -i | grep curl PHP已棄用:以'#'開頭的評論在第0行的未知中的第1行的/etc/php5/cli/conf.d/mcrypt.ini中棄用 –