[Answer]-Django-1.4.3 how to add categories?how posts when click on the category?

1👍

What you need is:

category_posts = category.posts_set.all()

or

category_posts = Posts.objects.filter(category=category)

I encourage you to read Django tutorial.

Leave a comment