I am creating a site using ASP.NET MVC with lots of jQuery and AJAX stuff, and I In the main menu does the rest sites work with AJAX as little as possible.
In the ideal scenario, I would like to have my main menu 1) 1) Load the main content with AJAX on the Javascript enabled by the user) Changing the URL in the address bar (Enabling Copy Copying) ) 3) My code is only in one place, which means that I do not want to see .aspx and do the same markup in a .ascx PartialView. / P>
No. 1) I have no problem though, I do not know how to get number 2 without reloading the page. Any ideas?
I know that the third digit may be can be solved by creating a scene which presents each partial view, but there is no good way around it? Before returning to the client, any way of "wrap" a partial view on the site master or some controller?
However, I agree with other comments about not loading content through AJAX # 2 is a common problem in your list, which often grows when working with AJAX and is answerable to it.
The only method of changing the URL without having to reload the browser is by adding a #
to the end. Example:
http://www.yoursite.com/Content/About/#some-identifier/
There is no other way.
Hope this helps ...
Comments
Post a Comment