That's exactly what I needed. Thanks a lot.
--
Gijs
On Aug 27, 4:31 pm, David Zhou wrote:
> On Thu, Aug 27, 2009 at 10:10 AM, gnijholt wrote:
> > Or is there a better way to generate a full archive page (per year,
> > per month)?
>
> You'll need to test this, but you should be able to do that
On Thu, Aug 27, 2009 at 10:10 AM, gnijholt wrote:
> Or is there a better way to generate a full archive page (per year,
> per month)?
You'll need to test this, but you should be able to do that with {%
ifchanged %}:
#view:
posts = Posts.objects.order_by('-pub_date')
#template
{% for post in po
Hello Django-users,
Actually it's more of a basic Python problem than a Django problem.
I'll try to be brief:
In the view, I'm looping through my posts as such:
---
def archive(request):
years = Post.objects.dates('pub_date', 'year')
for year in years:
print year.year
mon
3 matches
Mail list logo