SOAP_Attachment
| From: | Michiel Betel | Date: | Sun, 02 Oct 2005 18:44:05 +0000 |
| Subject: | SOAP_Attachment | ||
| Groups: | php.pear.general | ||
| Request: | Send a blank email to pear-general+get-21198@lists.php.net to get a copy of this message | ||
I'm trying to create a SOAP Client which attached a DIME attachment.
This is using pear::soap 0.9.1, Mail_Mime 1.3.1 & Net_DIME 0.3 installed
Problem is that the attachment does not get attached.. The call does get placed and the other
parameters are processed.
Can anyone point me to wh\at I'm missing cuz I'm stuck. Looking in SOAP/Client.php it seems to me that
$this->__attachments is never set, and thus __generate will never call makeDime, but I'm not sure I'm
interpreting the code correctly
Thanks! Michiel
Code I use is:
$soapclient = new SOAP_Client('https://certificaten.vecozo.nl/webservices/EDP/declareren.asmx?WSDL', true);
$soapclient->setOpt('curl', CURLOPT_VERBOSE, 1);
$soapclient->setOpt('curl', CURLOPT_SSL_VERIFYHOST, 0);
$soapclient->setOpt('curl', CURLOPT_SSL_VERIFYPEER, 0);
$soapclient->setOpt('curl', CURLOPT_SSLCERT, "../certificates/vecozo15cl.pem");
$soapclient->setOpt('curl', CURLOPT_SSLCERTPASSWD, "blablabla");
$soapclient->setOpt('curl', CURLOPT_CAINFO, "../certificates/cacert.pem");
$soapclient->setOpt('curl', CURLOPT_CAPATH, "../certificates");
$v = new SOAP_Attachment('declaratie','application/octet-stream','/var/www/dd/test/test.txt');
$params=array(
$v,
'email' => 'michiel@betel.nl',
'referentie' => 'test1234'
);
$options = array(
'attachments' => 'Dime',
'namespace' => "http://www.vecozo.nl/EDP/",
'soapaction' => '',
'trace' => 1
);
$result = $soapclient->call('IndienenDeclaratie', $params, $options);
print $soapclient->wire;
Attachment: [application/x-pkcs7-signature] S/MIME Cryptographic Signature smime.p7s
Attachment: [application/x-pkcs7-signature] S/MIME Cryptographic Signature smime.p7s