This is a CORS error ... a security precaution implemented by web browsers. It prevents your Javascript is attempting to make a RESTful call to a different URL (192.168.0.20) than it was served from (localhost).
You either need to serve the Javascript itself from that same origin (192.168.0.20) or add in a CORS filter to your web.xml, see eg [1] HTH Dan [1] https://github.com/incodehq/contactapp/blob/master/backend/webapp/src/main/webapp/WEB-INF/web.xml#L38 On 28 March 2016 at 22:25, Arturo Ulises Castañeda Estrada < arturo.castan...@sisorg.com.mx> wrote: > Hi Dan, > > > I'm trying to persist but the server says that i dont have access and u > get next error: > > > XMLHttpRequest cannot load http://192.168.0.20:8080/restful/user. > Response to preflight request doesn't pass access control check: No > 'Access-Control-Allow-Origin' header is present on the requested resource. > Origin 'http://localhost:8100' is therefore not allowed access. The > response had HTTP status code 401. > > >