Jump to content

PHP SOAP RESPONSE....HELP NEEDED!!!!!!!!!!!!


Recommended Posts

Ok so i've been integrating my website with a SOAP service that Amazon provide.

 

When I call:

 

 

$req = array('merchant' => array('merchantIdentifier' => $token, 'merchantName' => $name), 'documentIdentifier' => '591872944');

print_r($client -> __soapCall('getDocument', $req));

 

 

It is supposed to return an XML file of the document 591872944. Which it does, kind off....

 

The response starts as follows:

 

 

--xxx-WASP-CPP-MIME-Boundary-xxx-0xb04e270-0b04e270-xxx-END-xxx

Content-Type: text/xml; charset="UTF-8"

 

<SOAP-ENV:Envelope xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:SE="http://schemas.xmlsoap.org/soap/encoding/"><SOAP-ENV:Body><ns0:string_Response xsi:type="xsd:string" xmlns:ns0="http://systinet.com/xsd/SchemaTypes/">591872944 </ns0:string_Response><ns1:doc href="cid:0xaf6bc18-0xb41b9f8-0xafe85a0-0xb879518-0xb4b1820" xmlns:ns1="http://systinet.com/xsd/SchemaTypes/"/></SOAP-ENV:Body></SOAP-ENV:Envelope>

--xxx-WASP-CPP-MIME-Boundary-xxx-0xb04e270-0b04e270-xxx-END-xxx

Content-ID: <0xaf6bc18-0xb41b9f8-0xafe85a0-0xb879518-0xb4b1820>

Content-Type: application/binary

 

<?xml version="1.0" encoding="UTF-8"?>

<AmazonEnvelope xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="amzn-envelope.xsd">

<Header>

 

 

 

This is displaying the following error:

 

SoapFault exception: [Client] looks like we got no XML document in /var/www/1visual_bms/client.php:19

Stack trace:

#0 /var/www/1visual_bms/client.php(19): SoapClient->__soapCall('getDocument', Array)

#1 {main}

 

 

I believe it is because of the comment thing at the top...but I cannot remove this before the response is processed by PHP SOAP....

 

 

 

PLEASE HELP!!!

Link to comment
https://forums.phpfreaks.com/topic/154075-php-soap-responsehelp-needed/
Share on other sites

ober is right there is a lot of help from amazon website.

 

Documentation :

http://aws.amazon.com/documentation/

 

Sample code and Example (in C#, Java, PHP, Ruby, ....) :

http://developer.amazonwebservices.com/connect/kbcategory.jspa?categoryID=173

 

Amazon Developer Forum :

http://developer.amazonwebservices.com/connect/forumindex.jspa

 

And lot more...

http://aws.amazon.com/

  • 1 month later...

Unfortunately I have still not been able to find a solution for this problem!!

 

I would really appreciate any help...the amazon website has no such help for this problem.

 

My best guess is the fact that the response comes back with a line break at the start..? Either this or when I try to access via soapUI, the response contains a soap "attachment"

 

Anyone? Please?

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.