added prev/next links for traversing collections; fixes #189

@jcoyne: Since this is somewhat large, I thought I'd give you a chance to make comments if you have any. We might end up merging it before you get a chance though because of the demo tomorrow.
It makes sure that the positions are counted properly. I'll make the comment better.