javascript - XMLHttpRequest cannot load "THIS URL" Origin http://localhost:3000 is not allowed by Access-Control-Allow-Origin. -


im getting error when trying post , xml company website freshdesk api

here javascript

$(document).ready(function(){   var data =    '<helpdesk_ticket>' +     '<description>this test</description>' +     '<email>sample@example.com</email>' +    '</helpdesk_ticket>' $.support.cors = true; $.ajax({     url: 'http://onehouse.freshdesk.com/helpdesk/tickets.xml',     type: 'post',     crossdomain: true,     data: data,     datatype: "text",     username: 'my api code',     password: 'x',      success: function (result) {         alert(result);     },   }); 

the full error

xmlhttprequest cannot load http://onehouse.freshdesk.com/helpdesk/tickets.xml. origin http://localhost:3000 not allowed access-control-allow-origin. contacts?oid=00du0000000i430&returl=http%3a%2f%2fwww.ironridge.com&email=ma…utes%5d%5bdescription_html%5d=safsadfsdaf&00nu0000002xpyp=&submit=submit:1 

does have solutions this........it not post data freshdesk website , i've been banging heads days now

it says right there in error.

you cannot ajax requests (aside jsonp) different domain due access-control-allow-origin.


Comments

Popular posts from this blog

basic authentication with http post params android -

vb.net - Virtual Keyboard commands -

css - Firefox for ubuntu renders wrong colors -