Seeking sample template code for iterating nested QuerySet

2012-03-01 Thread brycenesbitt
The documentation at: https://docs.djangoproject.com/en/1.3/topics/db/queries/ Speaks of "Spanning multi-valued relationships", with an QuerySet returning all Entries (and their Blogs) where the Blog matches a pattern. What does the view code look like? When I do something similar: facets= mo

Re: Working Django forums code for integration?

2012-06-23 Thread brycenesbitt
I've had the same problem. > > AskBot : not a real forum, and a lot of dependencies. PyBBM: install instructions incomplete, no community to speak of, buggy. I had problems with csrf, and could not get any help. Cnprog: dead PyBB: dead DjangoBB: website reads "Documentation will be soon..." --

Re: Working Django forums code for integration?

2012-06-24 Thread brycenesbitt
Are there any forum packages not listed at > > http://www.djangopackages.com/grids/g/forums/ -- You received this message because you are subscribed to the Google Groups "Django users" group. To view this discussion on the web visit https://groups.google.com/d/msg/django-users/-/OefJfoaDiVoJ.

'CSRF verification failed." from django.contrib.comments. can you help solve it? django 1.3

2012-06-28 Thread brycenesbitt
I'm using django.contrib.comments and get 'CSRF token missing or incorrect.' when previewing or submitting a comment. I have: *MIDDLEWARE_CLASSES = (* *'django.middleware.csrf.CsrfViewMiddleware',* *'django.middleware.common.CommonMiddleware',* *'django.contrib.sessions.middleware.Se

Re: 'CSRF verification failed." from django.contrib.comments. can you help solve it? django 1.3

2012-06-29 Thread brycenesbitt
The "security_hash" field that you see is part of the comments app, and is > not the CSRF token. That needs to be output by a {% csrf_token %} tag (or > its equivalent). If it's working, you should see another hidden input > field, which looks like this: > > > value="36d43c1652d5676d6d41

Re: 'CSRF verification failed." from django.contrib.comments. can you help solve it? django 1.3

2012-06-29 Thread brycenesbitt
On Thursday, June 28, 2012 10:43:58 AM UTC-7, jonas wrote: > > After the starting form tag add {% csrf_token %} > I can't. It is rendered for me by {% render_comment_form for entry %} -- You received this message because you are subscribed to the Google Groups "Django users" group. To view thi

m2m through intermediate model: template friendly syntax not working. dj1.3

2012-07-13 Thread brycenesbitt
I'm able to get an intermediate m2m model to show data, but not with the template-friendly "_set" syntax: category= models.Category.objects.select_related().get(pk=pk) entries = category.entry.order_by('-temp_sort_order').filter(temp_sort_order__gte=0) for entry i

Re: 'CSRF verification failed." from django.contrib.comments. can you help solve it? django 1.3

2012-07-16 Thread brycenesbitt
It works now that I have fully uninstalled pybbm. Pybbm was incompatible with my app because it also extended the User object (something apparently you can only do once?) -- You received this message because you are subscribed to the Google Groups "Django users" group. To post to this group, sen

Re: m2m through intermediate model: template friendly syntax not working. dj1.3

2012-07-16 Thread brycenesbitt
> > Using 'for entry in category.ce_.all', as suggested elsewhere also fails >> > > -- You received this message because you are subscribed to the Google Groups "Django users" group. To view this discussion on the web visit https://groups.google.com/d/msg/django-users/-/qVATgZeGAWMJ. To po

Re: m2m through intermediate model: template friendly syntax not working. dj1.3

2012-07-16 Thread brycenesbitt
I'm still stuck on this. Is there any tutorial example that shows access m2m intermediate model data from a template. The issue is the template library won't accept parameters. Do I have to write a custom tag to get the m2m intermediate data fields? -- You received this message because you

Seeking example of django.contrib.staticfiles usage

2011-11-24 Thread brycenesbitt
I'm evaluating frameworks, writing the same app different ways. I've run smack into Django's static file handling. I understand that with Django my basic options for static files are: 1) Static files on a separate web server 2) Configure apache to send some content to Django, serve some stat

Cache witin a single transaction / session ?

2013-05-23 Thread brycenesbitt
Does there exist a lightweight cache option for django which persists data in a single session. For example: {{gallery.tiles.count}} item{% if gallery.tiles.count != 1 %}s{% endif %} Produces two count() operations on the underlying database. Is there a way to make that one operation? -- You