I have a similar setup - rails 3 backend with design as authentication. I use standard jquery, however, in a fully functional browser instead of a mobile one, and I have my users included in regular html forms.
so that my users are authenticated and able to make backjone / jquery ajax callbacks on my server, I had to add this to the rails.js file:
$.ajaxSetup({ beforeSend: function(xhr) { xhr.setRequestHeader('X-CSRF-Token', $('meta[name="csrf-token"]').attr('content')); } });
As soon as I put this in place, I no longer had to worry about authentication.
hope that helps
source share