MySQL Forums
Forum List  »  PHP

Re: Getting Previous and Next in a resultset.
Posted by: Navraj Singh
Date: January 30, 2006 04:21AM

I dont have any problem with the pagination. It is working fine. My problem is that I want links to previous and next on the products. I'll explain properly.

It is a dating site. The search results are shown on a page with the total resultset divided into pages. Now the person clicks on one profile to view its details. Now I want to put the "Previous","Next" and"Back to Search Results" links on the profile details page. It will allow the user to browse through the profiles in the order of the search results and not the actual sequential order.

What I thought was of putting all the id's in an array and storing that array in session or using the same query and traversing through the complete resultset to get the previous and next id of a record. But it will make things worse because the results can go upto 3000 records. Please suggest some other feasible solution.

Thanking you in advance.

Options: ReplyQuote


Subject
Written By
Posted
Re: Getting Previous and Next in a resultset.
January 30, 2006 04:21AM


Sorry, you can't reply to this topic. It has been closed.

Content reproduced on this site is the property of the respective copyright holders. It is not reviewed in advance by Oracle and does not necessarily represent the opinion of Oracle or any other party.