Skip to content

Commit

Permalink
update to search display options for kaskelix embedding
Browse files Browse the repository at this point in the history
git-svn-id: https://svn.berlios.de/svnroot/repos/yacy/trunk@3560 6c8d7289-2bf4-0310-a012-ef5d649a1542
  • Loading branch information
orbiter committed Apr 12, 2007
1 parent a922d94 commit 3e5cd34
Show file tree
Hide file tree
Showing 3 changed files with 30 additions and 2 deletions.
2 changes: 1 addition & 1 deletion htroot/env/xhtml-style.css
@@ -1,5 +1,5 @@
body {
background-color:#F8F8FF;
background-color:#FFFFFF;
margin:0;
}
* {
Expand Down
26 changes: 26 additions & 0 deletions htroot/yacysearch.html
Expand Up @@ -22,6 +22,28 @@

#(input)#
::
<form class="search small" action="yacysearch.html" method="get" accept-charset="UTF-8">
<div>
<fieldset class="yacys">
<input id="search" name="search" type="text" size="50" maxlength="80" value="#[former]#" onclick="document.getElementById('Enter').value = 'Search'" />
<input id="Enter" type="submit" name="Enter" value="Search" />
<input type="hidden" name="contentdom" value="#[contentdom]#" />
<input type="hidden" name="former" value="#[former]#" />
<input type="hidden" name="count" value="#[count]#" />
<input type="hidden" name="resource" value="#[resource]#" />
<input type="hidden" name="time" value="#[time]#" />
<input type="hidden" name="urlmaskfilter" value="#[urlmaskfilter]#" />
<input type="hidden" name="prefermaskfilter" value="#[prefermaskfilter]#" />
<input type="hidden" name="depth" value="#[depth]#" />
<input type="hidden" name="cat" value="#[cat]#" />
<input type="hidden" name="type" value="#[type]#" />
<input type="hidden" name="display" value="#[display]#" />
<input type="hidden" name="input" value="#[input]#" />
<input type="hidden" name="constraint" value="#[constraint]#" />
</fieldset>
</div>
</form>
::
<form class="search small" action="yacysearch.html" method="get" accept-charset="UTF-8">
<p class="yacylogo"><a href="http://yacy.net/yacy/" class="yacylogo"><img src="/env/grafics/yacy.png" alt="yacy" /></a></p>
<h2>#[promoteSearchPageGreeting]#</h2>
Expand Down Expand Up @@ -52,15 +74,19 @@ <h2>#[promoteSearchPageGreeting]#</h2>
<input type="hidden" name="cat" value="#[cat]#" />
<input type="hidden" name="type" value="#[type]#" />
<input type="hidden" name="display" value="#[display]#" />
<input type="hidden" name="input" value="#[input]#" />
<input type="hidden" name="constraint" value="#[constraint]#" />
</fieldset>
</div>
</form>
#(/input)#

#(searchagain)#
::
<script type="text/javascript">
document.getElementById("Enter").value = "search again - catch up more links";
</script>
#(/searchagain)#

<!-- show information about search key handling -->
#(excluded)#
Expand Down
4 changes: 3 additions & 1 deletion htroot/yacysearch.java
Expand Up @@ -93,7 +93,7 @@ public static serverObjects respond(httpHeader header, serverObjects post, serve
boolean authenticated = sb.adminAuthenticated(header) >= 2;
int display = (post == null) ? 0 : post.getInt("display", 0);
if ((display == 1) && (!authenticated)) display = 0;
int input = (post == null) ? 0 : post.getInt("input", 1);
int input = (post == null) ? 2 : post.getInt("input", 2);
String promoteSearchPageGreeting = env.getConfig("promoteSearchPageGreeting", "");
if (promoteSearchPageGreeting.length() == 0) promoteSearchPageGreeting = "P2P WEB SEARCH";

Expand All @@ -120,6 +120,7 @@ public static serverObjects respond(httpHeader header, serverObjects post, serve

// we create empty entries for template strings
final serverObjects prop = new serverObjects();
prop.put("searchagain", 0);
prop.put("input", input);
prop.put("display", display);
prop.put("input_input", input);
Expand Down Expand Up @@ -489,6 +490,7 @@ else if (yacyonline) {
for (int i=0; i<linkcount; i++)
prop.put("type_results_" + i + "_authorized", (authenticated) ? 1 : 0);

prop.put("searchagain", (global) ? 1 : 0);
prop.put("input", input);
prop.put("display", display);
prop.put("input_input", input);
Expand Down

0 comments on commit 3e5cd34

Please sign in to comment.