Hm, I thought that's what I had tried, obviously I was doing something slightly wrong. Oh well, it works now.
Thanks for your help :) bruno desthuilliers wrote: > As often with Python, the simplest thing to do is to fire a Python > shell and explore the problem: > > >>>> from django import template >>>> c = template.Context(dict(foo='foo', bar=range(3), baaz=dict(un=1, >>>> deux=2))) >>>> c >>>> > [{'baaz': {'un': 1, 'deux': 2}, 'foo': 'foo', 'bar': [0, 1, 2]}] > >>>> template.Variable('foo').resolve(c) >>>> > 'foo' > >>>> template.Variable('bar').resolve(c) >>>> > [0, 1, 2] > >>>> template.Variable('bar.0').resolve(c) >>>> > 0 > >>>> template.Variable('baaz.un').resolve(c) >>>> > 1 > >>>> template.Variable('50').resolve(c) >>>> > 50 > >>>> template.Variable('"string"').resolve(c) >>>> > 'string' > >>>> template.Variable('\'string\'').resolve(c) >>>> > 'string' > > > HTH > > > > > --~--~---------~--~----~------------~-------~--~----~ 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 django-users+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/django-users?hl=en -~----------~----~----~----~------~----~------~--~---