added pagination for pages, fixes #10