Re: Removing the logged in user's name from the list of users in django

2013-08-30 Thread C. Kirby
I think you can use "is", but try this: {% if not likes.user == request.user %} On Friday, August 30, 2013 12:21:41 PM UTC-5, Robin Lery wrote: > > > I am getting an error: > > TemplateSyntaxError at /forum/ > > Unused 'is' at end of if expression. > > > > On Fri, Aug 30, 2013 at 10:05 PM, C. Kir

Re: Removing the logged in user's name from the list of users in django

2013-08-30 Thread C. Kirby
To remove the current user from your list just use an if statement in your template that tests the user instance you are iterating over against request.user i.e. {% for likes in forum.likes.all %} {% if not likes.user is request.user %}{{likes.get_full_name}}{% endif

Re: Removing the logged in user's name from the list of users in django

2013-08-30 Thread Robin Lery
I can still see my name (the logged in user's name) on the list.. On Fri, Aug 30, 2013 at 10:05 PM, C. Kirby wrote: > To remove the current user from your list just use an if statement in your > template that tests the user instance you are iterating over against > request.user > i.e. > >