laravel-soap
laravel-soap copied to clipboard
Adding attribute to Envelope tag
Hello,
My XML looks something like this:
<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:urn="urn:string:string">
<soapenv:Header/>
<soapenv:Body>
<urn:apSrv>
<urn:dsContext>
<ttContext>
<contextGroup>PARAM</contextGroup>
<contextName>password</contextName>
<contextValue>xxxxxxxx</contextValue>
<contextOperator />
<contextType />
</ttContext>
<ttContext>
<contextGroup>PARAM</contextGroup>
<contextName>username</contextName>
<contextValue>xxxxxx</contextValue>
<contextOperator />
<contextType />
</ttContext>
</urn:dsContext>
</urn:apSrv>
</soapenv:Body>
</soapenv:Envelope>
I want to know how I can add the xmlns:urn="urn:string:string"
attribute to the Envelope tag. I need that in order for the call to work.
Thank you!
It seems that I need to override the __doRequest method in order to achieve that. Something like this:
https://www.binarytides.com/modify-soapclient-request-php/
Can that be done with your wrapper?