2015-07-20 128 views
-2

請你幫我捲曲命令轉換爲PHP:轉換捲曲cmd以PHP

curl -S -s --cacert GeoTrust_Primary_CA.pem-X -X POST -F "type=xml" -F 
"token= aGEMQB9Idh35fxxxxxxxxxxxxxQwyGlQ" -F "[email protected]:\batch.xml" 
https://www.fio.cz/ib_api/rest/import/> server_response.xml 2>error.log 
type error.log 

EXEC()不工作。

非常感謝。

切赫

+0

您需要更具體地瞭解什麼是「不工作」。你看到什麼錯誤信息?意外的輸出?還有別的嗎? – ethrbunny

回答

1

爲什麼不直接使用cURL PHP函數? 您可以找到here處理您的請求的所有選項。例如,您可以從此開始:

$request = curl_init($URL); 
    curl_setopt($request, CURLOPT_CUSTOMREQUEST, "POST"); 
    curl_setopt($request, CURLOPT_RETURNTRANSFER, true); 
    $response = curl_exec($request); 
    curl_close($request);