asp.net mvc - RedirectToAction() with tab-id -


i have web application in asp.net mvc , in there have jqueryui tab forms in. , when submit want return open tab.

with me redirecttoaction() create url

www.foo.com/cv/edit/9 

but want able generate

www.foo.com/cv/edit/9#tab-2 

i tried redirecttoaction("edit/"+id+"#tab-2"), generates:

www.foo.com/cv/edit/9%23tab-2 

any1 knows answer?

create url, append #tab-2 it. return redirectresult redirect created url:

return new redirectresult(url.action("edit", new { id }) + "#tab-2"); 

Comments

Popular posts from this blog

objective c - Change font of selected text in UITextView -

php - Accessing POST data in Facebook cavas app -

c# - Getting control value when switching a view as part of a multiview -