Re: newbie and slugs

2008-11-05 Thread Carmelly
Yes, you need to create the slug in your save() method. Something like: class Review(models.Model): ... def save(self): # add slug if there isn't one already if not self.slug: from django.template.defaultfilters import slugify self.slug = slugify(self.title

Re: newbie and slugs

2008-11-05 Thread William Purcell
I think my problem might be that I'm not saving the slug. When I save a review I do... review = Review(.) #< Everything but a slug gets passed as a kwarg review.save() #<--- Then I save the review. How do I save the slug when I save the review. Does Django automajically do thi