Ask is moving to Stack Overflow and! Please use the "opendaylight" tag on either of these sites. This site is now in Read-Only mode


OpenDaylight Toolkit simple project

asked 2014-12-08 00:11:05 -0700

Amir gravatar image


I have tried to run ODL toolkit;s simple project and I did exactly like the tutorial ( ). when I run the server and when i try to develop ( ) , the following error will appear:

Cross-Origin Request Blocked: The Same Origin Policy disallows reading the remote resource at http://localhost:8080/simple/northbound/simple . This can be fixed by moving the resource to the same domain or enabling CORS.

I have performed this command: nodejs provision.js --scaffold and I successfully ran the server.js

Does any body can help?

edit retag flag offensive close merge delete

1 answer

Sort by ยป oldest newest most voted

answered 2014-12-09 23:24:34 -0700

Amir gravatar image

just I added the following to app.js and problem solved:

$.ajaxSetup({ type: 'POST', username: 'admin', password: 'admin', data: {}, dataType: 'json', xhrFields: { withCredentials: true }, crossDomain: true, success: 'callback', headers: { 'Accept': 'application/json', 'Content-Type': 'application/json' } });

edit flag offensive delete publish link more
Login/Signup to Answer

Question Tools

1 follower


Asked: 2014-12-08 00:11:05 -0700

Seen: 157 times

Last updated: Dec 09 '14