Please upgrade here. These earlier versions are no longer being updated and have security issues.
HackerOne users: Testing against this community violates our program's Terms of Service and will result in your bounty being denied.
sorting search results by date
ithcy
New
Is there a way to sort search results by date?
or at least give the date more weight in the results relevance formula?
the search results seem to appear in random chronological order for hits that seem as though they should have equal relevance. i would think newer results should appear closer to the top if they're weighted the same, especially in a support forum as newer results are likely to have more up-to-date information. or are they? *shrug
on a side note, I can't believe i was posting here in 2005... hi nav! I mean Mark!
or at least give the date more weight in the results relevance formula?
the search results seem to appear in random chronological order for hits that seem as though they should have equal relevance. i would think newer results should appear closer to the top if they're weighted the same, especially in a support forum as newer results are likely to have more up-to-date information. or are they? *shrug
on a side note, I can't believe i was posting here in 2005... hi nav! I mean Mark!
3
Comments
->OrderBy('s.Relavence', 'desc')
Change this to;
->OrderBy('s.DateInserted', 'desc')
But this doesn't "combine" relavance and date, it just sorts them by date. I don't know how it assigns a relavance to a post or how it decides this.