Re: comma seperated lists

2009-05-31 Thread Brian May
On Fri, May 29, 2009 at 01:50:38AM -0700, V wrote: > if you do this to get a comma separated list you might like > https://launchpad.net/django-export-csv No, I don't use CSV here, but it is nice to know such a facility exists - I have used CSV for other projects. Thanks. -- Brian May --~--~--

Re: comma seperated lists

2009-05-31 Thread Brian May
On Fri, May 29, 2009 at 02:03:59AM -0700, Daniel Roseman wrote: > Alternatively, you could use the join filter: > > {{ object.photoperson_set.all|join:", " }} I considered that, however, I don't think I can set the tag for every person, and the result would be I cna't click on the items in the

Re: comma seperated lists

2009-05-29 Thread Daniel Roseman
On May 29, 6:15 am, Brian May wrote: > On Thu, May 28, 2009 at 11:36:10PM -0500, Alex Gaynor wrote: > > Loops put some vary helpful variables in the context, so you can do > > something like: > > > {% for pp in object.photoperson_set.all %}{{pp.person}}{% if not forloop.last %}, > > {% endif %} {

Re: comma seperated lists

2009-05-29 Thread V
if you do this to get a comma separated list you might like https://launchpad.net/django-export-csv On May 29, 7:15 am, Brian May wrote: > On Thu, May 28, 2009 at 11:36:10PM -0500, Alex Gaynor wrote: > > Loops put some vary helpful variables in the context, so you can do > > something like: > >

Re: comma seperated lists

2009-05-28 Thread Brian May
On Thu, May 28, 2009 at 11:36:10PM -0500, Alex Gaynor wrote: > Loops put some vary helpful variables in the context, so you can do > something like: > > {% for pp in object.photoperson_set.all %}{{pp.person}}{% if not forloop.last %}, > {% endif %} {% endfor %} Thanks. Looks like just what I was

Re: comma seperated lists

2009-05-28 Thread Alex Gaynor
On Thu, May 28, 2009 at 11:33 PM, Brian May wrote: > > Hello, > > Simple question, can I make the following list comma seperated without > inventing my own custom tag type? > > {% for pp in object.photoperson_set.all %}{{pp.person}} {% endfor %} > > I don't want a comma before the first item or af