Vanilla 1 is no longer supported or maintained. If you need a copy, you can get it here.
HackerOne users: Testing against this community violates our program's Terms of Service and will result in your bounty being denied.
Number of search results
When I search for something in a Vanilla forum, I get the results, which is nice, and I get to click on a "next" link to go to the next page of results, but I can't see anywhere how many results there are, or how many pages of results.
I think it would be quite nice, it's a bit of a difference between having two pages and twenty pages of results. If I get too many results I tend to try to restrict my search, or try other words, so I would really like it if you could see how many results were found.
Or am I just missing something obvious?
I think it would be quite nice, it's a bit of a difference between having two pages and twenty pages of results. If I get too many results I tend to try to restrict my search, or try other words, so I would really like it if you could see how many results were found.
Or am I just missing something obvious?
0
This discussion has been closed.
Comments
It doesn't give the exact number of results because it is inefficient to do so. It has an engine that guesstimates the number of results, and even if there are only 3 or 4 pages of results, it's still an estimate, and sometimes it is wrong (Have you ever clicked to see the last page of google results and had it bump you back to the page you were on with the last page link removed?).
Vanilla doesn't have any fancy search indexing or guesstimation engine. The only way to get the number of search results is to run the same query that gets the results for that page, minus the limit statement, and with count() function. It means that you put the database through over twice the work because it would have to: Search, Get all results, Group them and return the count, Search, Get all results, limit to that page worth of results.
The tables are indexed nicely, but it's still a very slow process to query against a text field with likes and a bunch of and/or statements.
So, in the name of speed, I got rid of search result count. It made the searches twice as fast when I did that.