This must be simple, but how can i do a redirect to http://myURL/index#tab1 without having to specify a url ?
I tried something like :
redirect_to :action=> 'index#tab1'
But it thinks it's an action an开发者_开发知识库d does not work (because of the # symbol actually).
Any ideas ?
You should be able to do:
redirect_to :action => 'index', :anchor => "tab1"
Perhaps this:
redirect_to 'index#tab1'
精彩评论