pagination now respects query string