Javascript JQuery无法处理soap响应

Javascript JQuery无法处理soap响应,javascript,jquery,html,css,soap,Javascript,Jquery,Html,Css,Soap,我编写了下面的代码来使用jquery处理soap xml响应,但是jquery无法读取响应。我在下面的代码中有没有语法错误?我在控制台中没有看到任何错误。soap消息格式或我阅读它的方式是否有任何错误 我对这种实现有点陌生 <!DOCTYPE html> <html> <head> <script class="jsbin" src="http://code.jquery.com/jquery-1.7.2.min.js"> </

我编写了下面的代码来使用jquery处理soap xml响应,但是jquery无法读取响应。我在下面的代码中有没有语法错误?我在控制台中没有看到任何错误。soap消息格式或我阅读它的方式是否有任何错误

我对这种实现有点陌生

 <!DOCTYPE html>
<html>
<head>
<script class="jsbin" src="http://code.jquery.com/jquery-1.7.2.min.js">       </script>
<script>

    var xml = '<soapenv:Envelope      xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:web="http://siebel.com/WebService">\
  <soapenv:Header/>\
  <soapenv:Body>\
  <web:UpdateWO_Input>\
     <web:Comments>?</web:Comments>\
     <web:WOStatus>?</web:WOStatus>\
     <web:WONum>?</web:WONum>\
  </web:UpdateWO_Input><soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:web="http://siebel.com/WebService">\
  <soapenv:Header/>\
  <soapenv:Body>\
    <web:UpdateWO_Input>\
        <web:Comments>?</web:Comments>\
        <web:WOStatus>?</web:WOStatus>\
        <web:WONum>?</web:WONum>\
    </web:UpdateWO_Input>\
   </soapenv:Body>\
   </soapenv:Envelope>\
   </soapenv:Body>\
  </soapenv:Envelope> '

  var myObj=new Array(); 
  var index = 0;
  $(document).ready(function(){
   $(xml)
    .find('UpdateWO_Input').find('Comments')
    .each(function(){
        myObj[index] = $(this).text();
      index +=1;
    });

   for(var i =0; i< myObj.length;i++){
       $('body').append(myObj[i]+"<br/>");
    }

  });

  </script>

  <meta charset=utf-8 />
  <title>JS Bin</title>
   <!--[if IE]>
     <script src="http://html5shiv.googlecode.com/svn/trunk/html5.js">  </script>
   <![endif]-->
   <style>
         article, aside, figure, footer, header, hgroup, 
            menu, nav, section { display: block; }
   </style>
    </head>
     <body>

var xml='1〕\
\
\
\
?\
?\
?\
\
\
\
\
?\
?\
?\
\
\
\
\
'
var myObj=新数组();
var指数=0;
$(文档).ready(函数(){
$(xml)
.find('UpdateWO_Input')。find('Comments'))
.each(函数({
myObj[index]=$(this.text();
指数+=1;
});
对于(变量i=0;i”;
}
});
JS-Bin
文章、旁白、数字、页脚、页眉、H组、,
菜单,导航,部分{显示:块;}

我得到了我问题的答案。javascript代码中需要进行以下更改

    var myObj=new Array(); 
    var index = 0;
      $(document).ready(function(){
      $(xml)
    .find('web\\:UpdateWO_Input')
    .each(function(){
        myObj[index] = $(this).text();
      index +=1;
    });

     for(var i =0; i< myObj.length;i++){
        $('body').append(myObj[i]+"<br/>");
     }

    });
var myObj=new Array();
var指数=0;
$(文档).ready(函数(){
$(xml)
.find('web\\:UpdateWO\u输入')
.each(函数({
myObj[index]=$(this.text();
指数+=1;
});
对于(变量i=0;i”;
}
});

我发现它可能有部分用处。非常感谢。