[Xapian-discuss] hits per page

Olly Betts olly at survex.com
Mon Apr 16 01:12:51 BST 2007


On Fri, Apr 13, 2007 at 02:32:14PM -0400, Michael A. Lewis wrote:
> I found that but changing it in the template from 10 to 20 seemed not
> to do anything. I even punted with a <input type=hidden
> name=HITSPERPAGE value="20">. This is the only change I want to make
> to the standard display and it looked easy. However it's still only
> showing me 10 results.

I think you're misunderstanding the code in the template.  That code
checks the value which has been set using CGI parameter HITSPERPAGE - if
it's not 10, then the template code generates a suitable "hidden input"
such that HITSPERPAGE is preserved for the next action.

You need to modify your static initial search form to include a hidden
field HITSPERPAGE, and once this has been passed to Omega, it will
"stick" if you search again, page forward, etc.

But there simply isn't currently a way that you can specify a different
default page size just by modifying the OmegaScript template...

Cheers,
    Olly



More information about the Xapian-discuss mailing list