Rob,
Thanks for the reply. In looking at that link I found out about the
Paginator Tag. Which I think is what I need. However, in reading the
documenation about that tag. It says 'To be used in conjunction with
the object_list generic view.' I am not using a generic view. I have
the following code in my view:
page = int(page) -1
posts = ObjectPaginator(request.session['test'], 1)
return render_to_response('search.htm', {
'posts':posts.get_page(page),
'page':page+1,
'next':posts.has_next_page(page),
'prev':posts.has_previous_page(page),
'start': posts.first_on_page(page),
'finish': posts.last_on_page(page),
'pages': posts.page_range}
)
//
I'm kinda lost in reading the documentation about the Paginator Tag.
I put a assert statement in my paginator function, however when I
accessed the template the assert statement never happened. Also, what
is '{% spaceless %}'. They say to put that in the template?
Thanks for any help
On Oct 19, 10:31 am, Rob Hudson <[EMAIL PROTECTED]> wrote:
> I don't think it's 100% to your specs but take a look at
> this:http://blog.localkinegrinds.com/2007/09/06/digg-style-pagination-in-d...
>
> It's close enough for tweaking to get you 95% of the way there
> (maybe).
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups
"Django users" group.
To post to this group, send email to django-users@googlegroups.com
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at
http://groups.google.com/group/django-users?hl=en
-~--~~~~--~~--~--~---