How to get data from mediawiki api using Angularjs? -


while try access wiki api using angularjs $http.get(), cors issues occured. here code

$http.get('http://en.wikipedia.org/w/api.php?action=query&prop=extracts&format=json&exintro=&titles=india') .success(function(data){ console.log('data' +data); });

and error message

xmlhttprequest cannot load https://en.wikipedia.org/w/api.php?action=query&prop=extracts&format=json&exintro=&titles=india. no 'access-control-allow-origin' header present on requested resource. origin 'null' therefore not allowed access.

use jsonp cross-site requests.


Comments

Popular posts from this blog

timeout - Handshake_timeout on RabbitMQ using python and pika from remote vm -

gcc - MinGW's ld cannot perform PE operations on non PE output file -

c# - Search and Add Comment with OpenXML for Word -