Jump to content

SOAP POST in XML message


Guest billkiphs
 Share

Recommended Posts

Guest billkiphs

"Extreme newbie. Feel free to laugh"I am trying to figure out the post command. Here is my current challenge. I have an example similiar to the one provided on this site. The example here is:POST /InStock HTTP/1.1Host: www.example.orgContent-Type: application/soap+xml; charset=utf-8Content-Length: nnn<?xml version="1.0"?><soap:Envelopexmlns:soap="http://www.w3.org/2001/12/soap-envelope"soap:encodingStyle="http://www.w3.org/2001/12/soap-encoding"> <soap:Body xmlns:m="http://www.example.org/stock"> <m:GetStockPrice> <m:StockName>IBM</m:StockName> </m:GetStockPrice> </soap:Body></soap:Envelope>When I check this in my xml editor, it says POST is an error. I get the same message in a the IE browser.Please educate me on how to use the post command!Thanks in Advance.

Link to comment
Share on other sites

Well, the first and most important thing you must understand is that

POST /InStock HTTP/1.1Host: www.example.orgContent-Type: application/soap+xml; charset=utf-8Content-Length: nnn

Is not part of the SOAP message. It's the HTTP header that is sent. Therefore, it's not written, only generated.Also, SOAP is not placed in static documents. It's used for communication across domains, but reading static files across domains doesn't requre SOAP. So it seems you get the idea wrong.It's really hard to explain. You need to posses higher PHP or ASP content to grasp it. I myself don't grasp it completely yet, but I'm sure of what I'm saying above.

Link to comment
Share on other sites

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 account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

×
×
  • Create New...