SOAP Web Service Errors Are Handled Externally To The ColdFusion Application Framework

<!--- Define WSDL url. --->
<cfset strURL = (
	"http://" &
	CGI.server_name &
	REReplace( CGI.script_name, "[^\\/]+[\\/][^\\/]+$", "", "one" ) &
	"Test.cfc"
	) />
 
 
<!--- Build SOAP Request XML. --->
<cfsavecontent variable="xmlRequest">
 
	<?xml version="1.0" encoding="utf-8" ?>
	<soap:Envelope
		xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/"
		xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
		xmlns:xsd="http://www.w3.org/2001/XMLSchema">
 
		<soap:Body>
 
			<Test />
 
		</soap:Body>
 
	</soap:Envelope>
 
</cfsavecontent>
 
 
<!--- Make SOAP request. --->
<cfhttp
	result="objSOAPResponse"
	method="post"
	url="#strURL#"
	username="#username#"
	password="#password#">
 
	<cfhttpparam
		type="header"
		name="soapaction"
		value=""
		/>
 
	<cfhttpparam
		type="xml"
		value="#Trim( xmlRequest )#"
		/>
 
</cfhttp>
 
 
<!--- Output the HTTP response. --->
<cfdump
	var="#objSOAPResponse#"
	label="CFHTTP Response"
	/>
 
<!--- Output the SOAP Response --->
<cfdump
	var="#XmlParse( objSOAPResponse.FileContent )#"
	label="SOAP Response"
	/>

For Cut-and-Paste