python - Page switching using AJAX in Django -


i trying create site navigation using ajax. have navigation menu links different views (using {% url name %} in template). thing trying load page content using ajax. page content trying load enclosed in content block ({% block content %}).

i found snippet http://djangosnippets.org/snippets/942/, want use views have defined , content using ajax.

any suggestions?

you should use django-pjax built kind of thing.

all have to, in base template, include whole page or block content based on whether request ajax or not.

django-pjax ajax calls using jquery , manipulates history using html5 push state api, way , gracefully degrades in ie older versions.


Comments

Popular posts from this blog

c# - SharpSVN - How to get the previous revision? -

c++ - Is it possible to compile a VST on linux? -

url - Querystring manipulation of email Address in PHP -