SCRIPT7002 XMLHttpRequest Network Error 0x2ef3, Could not complete the operation due to error 00002ef3

- Pranay on Jan 19 '15
- viewed 10649 times

This error I came across while making an ajax call using jquery ajax function. After a long analysis I was able to figure it out, so thought of sharing with everyone.

Error:

SCRIPT7002 XMLHttpRequest Network Error 0x2ef3, Could not complete the operation due to error 00002ef3

Solution:

This error I came across while making an ajax call using jquery ajax function. After a long analysis I was able to figure it out.

Set the contentType as ‘application/json; charset=utf-8‘ to resolve the issue.

Example:

$.ajax({
    ...
    data:data,
    contentType:"application/json; charset=utf-8",
    dataType:"json",
    ...
}

If the issue is not yet resolved then it could be improper json data that you are passing. to resolve this addJSON.stringify to the json data you are passing. i.e.,

$.ajax({
...
data: JSON.stringify({
    'param1':'val1',
    'param2':'val2',
    'param3':'val3'
    }),
contentType:"application/json; charset=utf-8",
dataType:"json",
...
}

About the author

Pranay Deegoju
Sitecore Certified Professional

A Software Engineer by profession, a part time blogger and an enthusiast programmer. You can find more about me here.



Leave your comments on this post here


SIGN UP AND GET LATEST UPDATES.

Recent Posts

×
 

Liked this article?

Subscribe with your email and get updates when ever a new article is posted.

By subscribing you agree to our privacy terms. We promise that we do not sell your data.