Ajax call returns nothing for secured sites URL,How to access secured sites in ajax? -


function loadmessages(){    $.ajax({       url :"https://www.yammer.com/api/v1/search.json?search=java",       async: false,       datatype: "json",       crossdomain: true,       success : function (data) {           alert(data);          var htmldata = "";         for(var cntr=0;cntr<data.messages.messages.length;cntr++){              htmldata += "<tr><td>"+data.messages.messages[cntr].content_excerpt+"</td></tr>"         }         alert("no of msgs"+data.messages.messages.length);         $("#text tbody").append(htmldata);         return data;       } }); } 

xmlhttprequest cannot load https://www.yammer.com/api/v1/search.json?search=java. no 'access-control-allow-origin' header present on requested resource. origin 'http://localhost:8002' therefore not allowed access. response had http status code 401.


Comments

Popular posts from this blog

c - Bitwise operation with (signed) enum value -

xslt - Unnest parent nodes by child node -

YouTubePlayerFragment cannot be cast to android.support.v4.app.Fragment -