Distributed Peer-to-Peer Web Search Engine and Intranet Search Appliance
Java decentralizedintranet-searchintranet-search-enginep2pp2p-networkprivacyprivacy-protectionsearch-enginesearchenginewebweb-search-enginewebsearchwebseearch-engine
fixed number of results counter on detailed search page
orbiter5c529bb34819
diff --git a/htroot/DetailedSearch.html b/htroot/DetailedSearch.htmlindex 93e041bc3..5d8bf6e81 100644--- a/htroot/DetailedSearch.html+++ b/htroot/DetailedSearch.html@@ -30,6 +30,10 @@/* ]]> */</script><h2>Detailed Search</h2>+ #(num-results)#+ ::+ <p><strong>#[linkcount]#</strong> results from <strong>#[orderedcount]#</strong> ordered links from <strong>#[filteredcount]#</strong> filtered links of a total number of <strong>#[totalcount]#</strong> known.</p>+ #(/num-results)#<form class="dsearch" action="DetailedSearch.html" method="get" enctype="multipart/form-data"><fieldset><input type="text" name="search" id="search" value="#[search]#" size="50" maxlength="250" />@@ -98,10 +102,6 @@::<p><strong>The following words are stop-words and had been excluded from the search: #[stopwords]#.</strong></p>#(/excluded)#- #(num-results)#- ::- <strong>#[linkcount]#</strong> results from <strong>#[orderedcount]#</strong> ordered links of a total number of <strong>#[totalcount]#</strong> known.- #(/num-results)##(combine)#::<p><strong>Topwords</strong> (to refine search):diff --git a/htroot/DetailedSearch.java b/htroot/DetailedSearch.javaindex a74ecbe48..4fb31da17 100644--- a/htroot/DetailedSearch.java+++ b/htroot/DetailedSearch.java@@ -178,14 +178,8 @@ public class DetailedSearch {if (prop == null || prop.size() == 0) {prop.put("num-results", 0);} else {- final int linkcount = Integer.parseInt(prop.get("type_linkcount", "0"));- final int orderedcount = Integer.parseInt(prop.get("type_orderedcount", "0"));- final int totalcount = Integer.parseInt(prop.get("type_totalcount", "0"));final Object[] references = (Object[]) prop.get("type_references", new String[0]);- prop.put("type_num-results", 1);- prop.put("type_num-results_linkcount", linkcount);- prop.put("type_num-results_orderedcount", orderedcount);- prop.put("type_num-results_totalcount", totalcount);+ prop.put("num-results", 1);int hintcount = references.length;if (hintcount > 0) {if (hintcount > 16) { hintcount = 16; }