fix for the search bug introduced in SVN 5449

git-svn-id: https://svn.berlios.de/svnroot/repos/yacy/trunk@5451 6c8d7289-2bf4-0310-a012-ef5d649a1542
pull/1/head
orbiter 16 years ago
parent d6a5c98080
commit 9bed4de280

@ -399,12 +399,10 @@ public class yacysearch {
prop.put("num-results_resnav", resnav.toString());
// generate the search result lines; they will be produced by another servlet
int m = Math.min(theQuery.displayResults(), totalcount);
for (int i = 0; i < m; i++) {
for (int i = 0; i < theQuery.displayResults(); i++) {
prop.put("results_" + i + "_item", offset + i);
prop.put("results_" + i + "_eventID", theQuery.id(false));
prop.put("results_" + i + "_display", display);
prop.put("results_" + i + "_nl", (i < m - 1) ? 1 : 0);
}
prop.put("results", theQuery.displayResults());
prop.put("resultTable", (contentdomCode <= 1) ? "0" : "1");

@ -18,7 +18,6 @@
"items": [
#{results}#
<!--#include virtual="yacysearchitem.json?item=#[item]#&eventID=#[eventID]#" -->
#(nl)#:: ,#(/nl)#
#{/results}#
],
<!--#include virtual="yacysearchtrailer.json?eventID=#[eventID]#" -->

@ -126,7 +126,8 @@ public class yacysearchitem {
prop.put("content_date822", plasmaSwitchboard.dateString822(result.modified()));
prop.put("content_ybr", plasmaSearchRankingProcess.ybr(result.hash()));
prop.putNum("content_size", result.filesize());
prop.put("content_nl", (item == 0) ? 0 : 1);
final TreeSet<String>[] query = theQuery.queryWords();
yacyURL wordURL = null;
try {

@ -1,4 +1,5 @@
#(content)#:: {
#(content)#::#(nl)#:: ,#(/nl)#
{
"title": "#[title]#",
"link": "#[link]#",
"description": "#[description]#",

Loading…
Cancel
Save