News for hackers. Stuff that matters.
Re:How to Wire Up Ruby on Rails and AngularJS as a Single-Pa... by tragic on Tuesday July 22, 2014 @10:19AM (#8069095)
> How did you handle getting your browser to talk to a server running on a different port? (Cross-origin requests)

Having run such things on entirely different servers, never mind localhost ports, what I needed to do was set the Access-Control-Allow-Origin http header in the rails controller (same principle applies to other frameworks). One simple guide is here: http://madhukaudantha.blogspot.co.uk/2011/05/access-control-...

Slightly ruined by that dreadful blogger interface, but there you go.

There are no comments on this comment yet.