分页完成后,我想在特定对象页面上执行下一个和上一个链接

I'm working about some listing and gallery in codeigniter with PHP. I've done all the searches and good search result page with pagination.

Now when I click on position in my search results list it gets me into page with single result, description etc.

My question is: how to smartly make "next" and "previous"links on this single result page? After clicking next it goes to the page of next result etc.

Is there any other way than storing full search results in some array while browsing?

You can store the search conditions instead (much smaller -> can be stored for a long time, so you don't need to obfuscate the UX by sometimes showing prev/next and sometimes not) and add some generic user-independent caching layer to the search results. (This assumes that search results are not personalized and don't change much in time.)