fyleow wrote:
> keyword = books.objects.get(headline__icontains=keyword) I would then split/reshape this list into a list of (keyword, list_of_books) tuples, so you have a structure like this: keywordsearch = [('python', [<Book 1>,<Book 7>]), ('coding',[<Book 3>,<Book 7>])] then in the template you loop "for kwmatch in keywordsearch". Then kwmatch.0 gives you the keyword, and kwmatch.1 gives you the list of books which you then loop over. Is that about right? Barry --~--~---------~--~----~------------~-------~--~----~ 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 [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/django-users -~----------~----~----~----~------~----~------~--~---