Re: Putting dictionary element according to another element's value

2010-03-16 Thread pjrhar...@gmail.com
On Mar 15, 2:38 pm, "ge...@aquarianhouse.com" wrote: > {% with o.id as key %}{{ dictionary.key }}{% endwith %} > > would be better, as in comments mentioned It might be, if it worked. That will try and look up dictionary['key'] still. Peter -- You received this message because you are subscr

Re: Putting dictionary element according to another element's value

2010-03-15 Thread ge...@aquarianhouse.com
{% with o.id as key %}{{ dictionary.key }}{% endwith %} would be better, as in comments mentioned On Mar 15, 3:14 pm, "pjrhar...@gmail.com" wrote: > You'll need a custom template tag. Something like this will probably > do: > > http://push.cx/2007/django-template-tag-for-dictionary-access > > Pe

Re: Putting dictionary element according to another element's value

2010-03-15 Thread pjrhar...@gmail.com
You'll need a custom template tag. Something like this will probably do: http://push.cx/2007/django-template-tag-for-dictionary-access Peter On Mar 12, 7:48 pm, Rishat Muhametshin wrote: > Hello everyone, > > I just can't solve a problem. I have an array of dictionaries each having > random fie

Putting dictionary element according to another element's value

2010-03-12 Thread Rishat Muhametshin
Hello everyone, I just can't solve a problem. I have an array of dictionaries each having random fields, and those fields are referenced in another variable, like this: something = { "headers": [{"name": "first", "value": "From"}, {"name": "two", "value": "To"}], "content": [{"first": "Al