Home › forums › Chart Support › $.getJSON is not working
I am trying to run the sample code that you have given in the ‘JavaScript Charts from JSON Data API and AJAX’ section. But when I run it in any browser, it returns a blank page and I think the $.getJSON is not working. Can you please suggest a workaround? I am taking the program given by you as it is, but still there is no graph.
@nitin_nn,
For security reasons, browsers restrict cross-origin requests. JSONP allows you to sidestep the cross-origin requests. Please refer JSONP for more info.
You can also take a look at this jsFiddle for an example on JSONP.
— Vishwas R Team CanvasJS
Thanks for the reply. Even after using JSONP, it is still displaying a blank page. Can you do the modification in the your original source code and post here? I am new to web programming.
Please download static html from here.
You must be logged in to reply to this topic.