On Tue, Mar 3, 2009 at 4:57 PM, Bobby Roberts <tchend...@gmail.com> wrote:
> > > on my template i have: > > > > {% au.id|getbidstatus %} > > > > if i try {% au.id|getbidstatus(request.user.id) %}, I get this: > > > > Could not parse the remainder: '(request.user.id)' from 'au.id| > > getbidstatus(request.user.id)' > > > ok ... I'M LOOKING AT THE DOCS and i'm closer but it's only doing the > literals, not the values: > > > template side i have: > > {% getbidstatus au.id request.user.id %} > > > > in my py file for my template tags i have this: > > > @register.tag(name="getbidstatus") > > def do_getbidstatus(parser, token): > tagname, auctionid, bidderid = token.split_contents() > assert False, auctionid > > > > when i run it and get the assertion error, it prints au.id, not the > value of au.id > > what am i doing wrong? > > > > http://docs.djangoproject.com/en/dev/howto/custom-template-tags/#passing-template-variables-to-the-tag Alex -- "I disapprove of what you say, but I will defend to the death your right to say it." --Voltaire "The people's good is the highest law."--Cicero --~--~---------~--~----~------------~-------~--~----~ 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 django-users+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/django-users?hl=en -~----------~----~----~----~------~----~------~--~---