Jeff is correct in saying that templates are just for handling layout.
Django is quite strict about enforcing this separation. Having worked
with a slew of other languages myself I can understand that this can
be a tad inconvenient at times (even if it is best practice). A
possible solution is to
Vicky wrote:
> Is there any way to create a variable within the templates...?
>
You'll need to be more specific. What exactly are you trying to do?
You can define anything you need in your view, and then pass it to the
template. Logic belongs in the view. Templates are only there to put
that da
2 matches
Mail list logo