Rails Routes - Redirecting Paths for Deep Linking, hashchanges?
I'm using the jQuery hashchange plugin for deep linking in an ajax app.
Before I had URLs like so:
http://www.site.com/groups/1
Now to ajax the site links all look like this:
http://www.site.com/#/groups/1
This has become a challenge as it requires modification to the link_to helper to generate links correctly. And I just learned that it messes with Devise, so if a user who is not signed in loads, http://www.site.com/#/groups/1 devise doesn't retain that URL for redirection after a successful signin.
So I was wonderi开发者_开发知识库ng if there is a way I can keep the existing URL structure and have the Rails Route file redirect certains paths like so:
http://www.site.com/groups/1
to
http://www.site.com/#/groups/1
http://www.site.com/groups/1/tasks/31
to
http://www.site.com/#/groups/1/tasks/31
Any thoughts or suggestions on solving for this use case w/o hacking everything up?
Thanks
No there isn't such way.
Hash "#" sign can't be sent to server.
精彩评论