python - Django generic views - sending data to project templates -
i try send data generic views app urlpatterns = patterns('', (r'*', listview.as_view( queryset=post.objects.all().order_by("-created")[:2], template_name="/mysite/templates/index.html" )), ) however, data cannot sent c/p query , result returned. what's missing? in mysite/templates/index.html {% post in object_list %} {{ post.title }} {% endfor %} prints nothing you not providing enough information. r'*' not valid regular expression - * needs act on - , django report if tried use in urlconf. need show how including url in main urls.py.