I'm having a problem with how jQuery mobile works with RESTful actions in Rails.
For this explaination, let's assume I have a resource called Planet
and a PlanetsController
and I'm attempting to create a new Planet
by sending a post request from /planets/new
to /planets
. If this action succeeds, my URL is now /planets
even though it's actually showing /planets/1
. If the action failed, my URL is also now /planets/
instead of /planets/new
.
In both of these cases, if I click the Back button to go back to the index action, it won't work because jQuery Mobile thinks I'm already on /planets
. I have to reload the page in order to get back.
Is there a way to fix this so normal Rails RESTful actions can be used?