mod for small parameter

Post Reply
Equinoxe58
Posts: 14
Joined: Fri Oct 06, 2023 8:02 pm

mod for small parameter

Post by Equinoxe58 »

Hi,
In Admin/parameters, we have this parameter : Show only the 2 most relevant links from each site (a la google) for listing only 2 results.
In a mod, is it possible to change value (3, 4, 5 or more) results and not only 2 ?

while waiting for a mod if it is feasible, can you tell me where this parameter is located in search_results (I suppose it is there)
I would like to increase the value to 5 results
In advance, thank you for your answer
User avatar
captquirk
Site Admin
Posts: 299
Joined: Sun Apr 09, 2017 8:49 pm
Location: Arizona, USA
Contact:

Re: mod for small parameter

Post by captquirk »

The search finds all results for a query. It displays the top result for each domain found, then indented with the second top result within each domain. Sometimes there is no second. There is no way to modify the code to show more.

I think I understand what you are trying to accomplish, which is to show only the most relevant links and not ALL links. There is another search option in settings which limits how many results get returned. "Floor for query scores" controls this. A "0" returns everything. "20" returns anything with a score from 80.01 to 100%, "40" anything from 60.01% and up, "60" floor is 40.01%, and "80" is 20.01% or greater.

It is probably possible to modify the code for the "floor" to be a hard number and not a score limitation. This would be a hard number for overall returns and not discriminate by domain. Of course, if there is only site in the database, there will only be one domain and that would no longer be an issue.

Any modifications would be in searchfuncs.php in the area of lines 583-590.
Post Reply