create pagination on search page