| 123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263 |
- function FaultDialog(oCV) {
- this.m_oCV = oCV;
- }
- FaultDialog.prototype = new IFaultDialog();
- FaultDialog.prototype.show = function(soapFault) {
-
-
- if(typeof console != "undefined") {
- console.log("FaultDialog - an unhandled soap fault was returned: %o", soapFault);
- }
- };
- FaultDialog.prototype.handleUnknownHTMLResponse = function(responseText) {
-
-
- this.m_oCV.setTracking("");
- this.m_oCV.setConversation("");
- if (responseText) {
-
-
-
- if(this.m_oCV.envParams["useAlternateErrorCodeRendering"]){
- var headNode = document.getElementsByTagName("head")[0];
- var bodySrc = responseText.match(/<body[^>]*>([\s\S]*)<\/body>/im)[1];
-
- var scriptRegEx = /<script[^>]*>([\s\S]*?)<\/script>/igm;
- var scriptNode = scriptRegEx.exec(responseText);
- while (scriptNode != null) {
- var aScript = document.createElement("script");
- aScript.type= 'text/javascript';
- var scriptSrc = scriptNode[0].match(/src="([\s\S]*?)"/i);
- if (scriptSrc == null){
- aScript.text= scriptNode[1];
- } else {
- aScript.src = scriptSrc[1];
- }
- headNode.appendChild(aScript);
- scriptNode = scriptRegEx.exec(responseText);
- }
- document.body.innerHTML = bodySrc;
- } else {
- document.write(responseText);
- }
- }
- };
|