working pagination! messy messy code, this is a paranoid commit
fix some pagination bugs relating to hrefs
make pagination code as pretty as pagination UI