From: Ned Batchelder <n...@nedbatchelder.com>
Date: Sun, 02 Dec 2007 12:59:37 -0500
Local: Sun, Dec 2 2007 12:59 pm
Subject: Re: making two-column table from one-column data
If your data is in the 'data' context variable, then try this:
<table> It's a little awkward, and doesn't generalize to more than two columns, If you're willing to add some code to your view, you can get more columns: In the view: context['data'] = data In the template: <table> --Ned. andrej kesely wrote: -- > hi, > i have small question: > suppose i have data in QuerySet - ['A', 'B', 'C', 'D', 'E', 'F', > 'G']. > I want make from this set two-column table in my template: > A B > What is the fastest way to do it? I don't want split the QuerySet in > Thanks, Ned Batchelder, http://nedbatchelder.com You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
| ||||||||||||||
