On 10/31/06, Rob Hudson <[EMAIL PROTECTED]> wrote: > When I send a GET request, I do get the right header: > > X-Object-Type: blog.post > X-Object-Id: 1 > > (Wait, those are actually two different things in two different places > in Django. Hmmm...)
Ah, it wasn't clear to me which X- headers you meant. django.core.xheaders.populate_xheaders does the thing you're looking for; grepping the tree shows it's called from generic views (which you observed) and flatpages. But there's no magic about it, just call that function with the appropriate parameters. See here for an example: ./django/views/generic/date_based.py ... response = HttpResponse(t.render(c), mimetype=mimetype) populate_xheaders(request, response, model, getattr(obj, obj._meta.pk.name)) --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Django users" group. To post to this group, send email to django-users@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/django-users -~----------~----~----~----~------~----~------~--~---