-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA256
Rapis escribió:
> Second always set context_instance to RequestContext:
> render_to_response("some_template.html", {},
> context_instance=RequestContext(request))
>
> Annoying thing, that I can't forget to do it in one way, and also I
> have to repeat on all views responses...
> Is there anyway, to avoid these repeating all the time? For example,
> maybe it is possible to set context_instance to RequestContext?
Use a decorator to do the render for you. Thats what I do.
Regards.
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2.0.9 (GNU/Linux)
iEYEAREIAAYFAkojHB8ACgkQNHr4BkRe3pKXRwCdGL132wSd0tbDAI/vHHKqSBCj
8ksAoKXNw8SbZ509x72kGiw+ep05xHaN
=mcni
-----END PGP SIGNATURE-----
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups
"Django users" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/django-users?hl=en
-~----------~----~----~----~------~----~------~--~---