Whick is the best way to POST, PUT and DELETE from Backbone app to Rails app on different subdomains?
I have tried to fetch some data with Backbone from the Rails app and it works. I have tried to save new content with Backbone to Rails app.
I have real problems with PUT (updating a created model in database). I don't know why, but when I do in my backbone app something like: book.save()
And the book is a model that already existis on the database, instead of sendind a PUT petition to the Rails APP, it is sending an OPTIONS petition, and whithout the data.
Ideally, I want to send a PUT petition from the Backbone app to the Rails app, so I can do something like this in my Rails app:
Book.update_attributes params[:book]
The Rails App and the Backbone app are on different subdmains on same top level domain.