jquery调用webservice需要把XML数据做转换,转换成json才能用。
这样就需要在webconfig中添加:
<
httpHandlers
>
removeverb = " * " path *.asmx /> addverb validate false type System.Web.Script.Services.ScriptHandlerFactory,System.Web.Extensions,Version=3.5.0.0,Culture=neutral,PublicKeyToken=31BF3856AD364E35 </ >
这样就能直接用webservice返回的数据了。removeverb = " * " path *.asmx /> addverb validate false type System.Web.Script.Services.ScriptHandlerFactory,System.Web.Extensions,Version=3.5.0.0,Culture=neutral,PublicKeyToken=31BF3856AD364E35 </ >