@register.assignment_tag
def get_latest_blog_entries(limit=5):
 return BlogEntry.objects.order_by('-pub_date')[:limit]

@ register . assignment_tag def get_latest_blog_entries ( limit = 5 ) : return BlogEntry . objects . order_by ( '-pub_date' ) [ : limit ]
return limit of latest blog entries .