fixed type/cat properties

git-svn-id: https://svn.berlios.de/svnroot/repos/yacy/trunk@2002 6c8d7289-2bf4-0310-a012-ef5d649a1542
pull/1/head
orbiter 19 years ago
parent 47b541b2d1
commit c5087710a4

@ -117,7 +117,8 @@ public class index {
prop.put("results", "");
prop.put("urlmaskoptions", 0);
prop.put("urlmaskoptions_urlmaskfilter", ".*");
prop.put("type", "href");
prop.put("cat", "href");
prop.put("type", "0");
prop.put("depth", "0");
return prop;
}

@ -51,6 +51,7 @@ picPlus.src = "/env/grafics/plus.gif";
<input type="hidden" name="time" value="#[time]#">
<input type="hidden" name="urlmaskfilter" value="#[urlmaskfilter]#">
<input type="hidden" name="depth" value="#[depth]#">
<input type="hidden" name="cat" value="#[cat]#">
<input type="hidden" name="type" value="#[type]#">
</form>
</p><hr>

@ -108,7 +108,7 @@ public class yacysearch {
prop.put("resource", "global");
prop.put("time", 6);
prop.put("urlmaskfilter", ".*");
prop.put("type", "href");
prop.put("cat", "href");
prop.put("depth", "0");
prop.put("type", 0);
prop.put("type_excluded", 0);
@ -131,7 +131,7 @@ public class yacysearch {
serverObjects prop = new serverObjects();
if (post.get("type", "href").equals("href")) {
if (post.get("cat", "href").equals("href")) {
prop.put("type", 0); // set type of result: normal link list
final TreeSet query = plasmaSearchQuery.cleanQuery(querystring);
@ -299,7 +299,8 @@ public class yacysearch {
prop.put("resource", (global) ? "global" : "local");
prop.put("time", searchtime / 1000);
prop.put("urlmaskfilter", urlmask);
prop.put("type", "href");
prop.put("type", "0");
prop.put("cat", "href");
prop.put("depth", "0");
// adding some additional properties needed for the rss feed
@ -309,14 +310,12 @@ public class yacysearch {
}
if (post.get("type", "href").equals("image")) {
prop.put("type", 1); // set type of result: image list
if ((post.get("cat", "href").equals("image")) && (querystring.startsWith("http://"))) {
int depth = post.getInt("depth", 0);
if (querystring.startsWith("http://")) {
try {
plasmaSearchImages si = new plasmaSearchImages(sb.snippetCache, 6000, new URL(querystring), depth);
URL url = null;
try {url = new URL(querystring);} catch (MalformedURLException e) {}
plasmaSearchImages si = new plasmaSearchImages(sb.snippetCache, 6000, url, depth);
Iterator i = si.entries();
htmlFilterImageEntry ie;
int c = 0;
@ -326,11 +325,10 @@ public class yacysearch {
c++;
}
prop.put("type_results", c);
} catch (MalformedURLException e) {}
}
prop.put("cat", "image");
prop.put("type", 1); // set type of result: image list
prop.put("former", post.get("search", ""));
prop.put("type", "image");
prop.put("depth", depth);
}
// return rewrite properties

Loading…
Cancel
Save