I was checking how to perform SOAP calls without using any library like jax-ws, just using a normal HttpURLConnection. When reading documentation I found in some places
conn.setRequestProperty("SOAPAction", soapAction);
And in other places
conn.setRequestProperty("SOAPAction:", soapAction);
But I couldn't find the difference between these two headers. Well, I found one, when using "SOAPAction:", if the action was misspelled, the ":" was like part of the name of the action.
Does someone know the difference? Or is "SOAPAction:" simply wrong?
SOAPAction:
is wrong. HTTP adds the colon. A colon isn't allowed in a header name, in fact.
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.