ohrstedtl Posted March 15, 2014 Share Posted March 15, 2014 Hello I want to get data from a webservices and use file_get_contents() to send the request to the server. When I used WireShark to look at what is sent I found that the url is stripped. Here is the output from WireShark for the first block: POST /sweaWS/services/SweaWebServiceHttpSoap12Endpoint HTTP/1.0 Accept-Encoding:gzip,deflate Content-type:application/soap+xml;charset=UTF-8;action='urn:getLatestInterestAndExchangeRates' Content-Length:2881 Host:swea.riksbank.se:80 Connection:Keep-Alive User-Agent:Apache-HttpClient/4.1.1 (java 1.5) <soap:Envelope xmlns:soap="http://www.w3.org/2003/05/soap-envelope" xmlns:xsd="http://swea.riksbank.se/xsd"><soap:Header/><soap:Body><xsd:getLatestInterestAndExchangeRates><languageid>sv</languageid><seriesid>SEKATSPMI</seriesid> <!--Österrike, shilling--><seriesid>SEKAUDPMI</seriesid> <!--Australien, dollar --><seriesid>SEKBEFPMI</seriesid> <!--Belgien, franc --><seriesid>SEKBRLPMI</seriesid> <!--Brasilien, real --><seriesid>SEKCADPMI</seriesid> <!--Canada, dollar --><seriesid>SEKCHFPMI</seriesid> <!--Schweiz, franc --><seriesid>SEKCNYPMI</seriesid> <!--Kina, yuan renminbi --><seriesid>SEKCYPPMI</seriesid> <!--Cypern, pund --><seriesid>SEKCZKPMI</seriesid> <!--Tjeckien, kronor --><seriesid>SEKDEMPMI</seriesid> <!--Tyskland, mark --><seriesid>SEKDKKPMI</seriesid> <!--Danmark, kronor --><seriesid>SEKEEKPMI</seriesid> <!--Estland, kronor --><seriesid>SEKESPPMI</seriesid> <!--Spanien, pesetas --><seriesid>SEKEURPMI</seriesid> <!--Euroland, euro --><seriesid>SEKFIMPMI</seriesid> <!--Finland, mark --><seriesid>SEKFRFPMI</seriesid> <!--Frankrike, franc --><seriesid>SEKGBPPMI</seriesid> <!--Storbritannien, pund --><seriesid>SEKGRDPM So I wonder if I do the write thing or are missing something in my code. I run a program (MAMP PRO) locally to do the tests so I can use WireShark to look at the communication. Attached is the php file I used. soap1.php Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now