我在SOAP请求中遇到以下错误:
with open('/ThisIsTheFile', 'rU') as csvread:
reader = csv.reader(csvread, delimiter=',')
with open('/ThisIsTheFile', 'rU') as csvread2:
reader2 = csv.reader(csvread2, delimiter=',')
#Do Stuff
我尝试了什么?
SoapFault exception: [HTTP] Error Fetching http headers in /var/www/mtes/public_html/application/libraries/banks_with_api/pnb.php:132
Stack trace:
#0 [internal function]: SoapClient->__doRequest('<?xml version="...', 'http://124.124....', 'http://tempuri....', 1, 0)
#1 /var/www/mtes/public_html/application/libraries/banks_with_api/pnb.php(132): SoapClient->__call('GetTransactionS...', Array)
#2 /var/www/mtes/public_html/application/libraries/banks_with_api/pnb.php(132): SoapClient->GetTransactionStatus(Array)
#3 /var/www/mtes/public_html/application/controllers/test.php(12): PNB->transaction_status('200815101030342...')
#4 [internal function]: Test->pnb_test()
#5 /var/www/mtes/public_html/system/core/CodeIgniter.php(359): call_user_func_array(Array, Array)
#6 /var/www/mtes/public_html/index.php(220): require_once('/var/www/mtes/p...')
#7 {main}
CODE
我想在xml下面作为对web服务的请求:
ini_set("default_socket_timeout", 120);
为此,PHP代码如下:
<?xml version="1.0" encoding="utf-8"?>
<soap:Envelope xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/">
<soap:Body>
<GetTransactionStatus xmlns="http://tempuri.org/">
<TxnReferenceNo xmlns="http://PNB_Inward_Remittance.RemittanceStatusReceive" />
</GetTransactionStatus>
</soap:Body>
</soap:Envelope>