Could not complete the operation due to error80020101

 Could not complete the operation due to error80020101

$.ajax({
                    type: "POST",
                    url: window.prefixURL + '/CalendarHandler/InsertCalendarEventData2?callback=?',
                    contentType: 'application/json;charset=utf-8',
                    data: { "data": myjson.stringify(data) },
                    dataType: 'json',
                    success: function (doc) {
…….

解决方法:只要把URL地址后面 ?callback=? 去掉就OK了,由原先的JSONP方式改成JSON之后,没有去掉这个参数。

 

个人推断是由于JQuery解析的时候,遇到这个?callback=? 参数,就当做JSONP来处理,即使dataType指定为json也会按照JSONP来解析,从而导致parsError的错误。

相关文章:

  • 2022-12-23
  • 2022-12-23
  • 2021-07-05
  • 2022-12-23
  • 2022-12-23
  • 2021-05-31
  • 2022-01-07
  • 2021-09-01
猜你喜欢
  • 2021-07-24
  • 2021-11-08
  • 2022-01-10
  • 2021-05-29
  • 2022-12-23
  • 2022-12-23
  • 2021-08-03
相关资源
相似解决方案