oh, yah - i could do this in my controller before returning it - no duh...

thx Yarko (again...)

-wj

On Wed, Nov 19, 2008 at 11:39 AM, Yarko Tymciurak <[EMAIL PROTECTED]> wrote:
> two separate comments:
> - if initializing a dict is not working in templating engine, then that
> should be worked out;
> - do the sorting in your controller - let your view do color / layout
> management - don't force data manipulation on it if you can avoid it...
> unless you want to be doing this under user control (like sorting by columns
> on the screen) - in which case, there are probably other options for this (I
> remember seeing some jQuery plugins discussed for this on this group)
>
>
> On Wed, Nov 19, 2008 at 12:24 PM, Wes James <[EMAIL PROTECTED]> wrote:
>>
>> What I'm trying to do is sort a dict passed from my controller:
>>
>> {{a=schols.items()}}
>> {{a.sort()}}
>> {{schols={}}}
>> {{for b in a:}}
>> {{schols[b[0]]=b[1]}}
>> {{pass}}
>>
>> bye the way Massimo, I commented out the code above in my layout, and
>> I had to do this with the for line for it to comment out right - I
>> thought you had fixed this (per your previous comment about doing
>> this.)
>>
>> {{#for b in a:#}}
>>
>>
>> thx,
>>
>> -wj

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"web2py Web Framework" group.
To post to this group, send email to web2py@googlegroups.com
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/web2py?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to