13

I am trying to access cross origin site via script.

So I am getting an error, I have searched on internet that shows the solution is the JsonP.

Anyone Please help me to know what is jsonp .

and what is the difference between json and jsonp.

Is JSONP cross browser compatible? can i use jsonp in mobile applications or asp.net mvc?

0

1 Answer 1

17

JSONP is a simple way to overcome browser restrictions when sending JSON responses from different domains from the client.

But the practical implementation of the approach involves subtle differences that are often not explained clearly.

Here is a simple tutorial that shows JSON and JSONP side by side.

All the code is freely available at Github and a live version can be found at http://json-jsonp-tutorial.craic.com

3
  • 2
    as of April 2017, the link to json-jsonp-tutorial is down.
    – PaulDong
    Commented Apr 4, 2017 at 7:58
  • @faridcs json-jsonp-tutorial.craic.com is not working :( Commented Apr 12, 2017 at 6:52
  • 5
    Replaced dead link to JSON tutorial with Web Archive version
    – SiHa
    Commented May 3, 2017 at 11:53

Not the answer you're looking for? Browse other questions tagged or ask your own question.