Something I tried once: set the 'extends' template variable in your views (middleware even, maybe) to either an empty string or the path to your template, based on the result of request.is_ajax.
I'm not sure though whether Django will throw an error if extends has an empty string. Suggestion: def my_view(request): context = {} context['extends'] = 'base.html' if request.is_ajax() else '' ..... return render_to_response('mytemplate.html', context) template: {% extends extends %} Not sure if that will work, just a guess. -- You received this message because you are subscribed to the Google Groups "Django users" group. To post to this group, send email to django-us...@googlegroups.com. To unsubscribe from this group, send email to django-users+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/django-users?hl=en.