yacy_search_server/htroot/index.html
apfelmaennchen 4d7ae76017 - update to jquery 1.7 (does not apply to all jquery code, old version is additionally kept for compatibility)
- update to jquery-ui 1.8.16 (includes themes)
- introduced new portalsearch (as default)
- old portalsearch is still available and accessible, but will eventually be removed
- jquery and portal search is now loaded by special header templates for maintenance reasons
- update to new autocomplete, solves bug: http://bugs.yacy.net/view.php?id=29
- many improvements to YMarks GUI and API...more to come anytime soon

Sorry, this is a rather large commit, I hope it doesn't break anything essential, but I need to consolidate some of my efforts in order to move ahead. Especially the update to the portalsearch widget might not be welcomed, but the old one is simply incompatible with newer jquery and jquery-ui libraries, sorry. The code tree /yacy/ui/... is obsolete and will be removed in the future. At that point all productive portalsearches should have migrated to the new version.



git-svn-id: https://svn.berlios.de/svnroot/repos/yacy/trunk@8014 6c8d7289-2bf4-0310-a012-ef5d649a1542
2011-11-07 20:44:58 +00:00

184 lines
7.8 KiB
HTML

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
#(forward)#::<meta http-equiv="REFRESH" content="0; url=#[target]#" />#(/forward)#
<title>YaCy '#[clientname]#': Search Page</title>
#%env/templates/metas.template%#
<link rel="alternate" type="application/rss+xml" title="Search for #[former]#" href="yacysearch.rss?query=#[former]#" />
<link rel="search" type="application/opensearchdescription+xml" title="YaCy Search on '#[clientname]#'" href="opensearchdescription.xml" />
<script type="text/javascript" src="js/html.js"></script>
<style>
.ui-autocomplete-input {
margin: 0 0.2em;
padding: 0;
}
</style>
<script type="text/javascript">
$(document).ready(function() {
$("#search").autocomplete({
source: function( request, response ) {
$.ajax({
url: "/suggest.json",
dataType: "json",
data: {
q: request.term,
limit: 20,
timestamp: +new Date()
},
success: function(data) {
response( $.map( data[1], function(term) {
return {
label: term,
value: term
}
}));
}
});
},
minLength: 2,
select: function( event, ui ) {
// ui.item.label
// ui.item.value
// this.value
this.value = ui.item.value;
},
open: function() {
$( this ).removeClass( "ui-corner-all" ).addClass( "ui-corner-top" );
},
close: function() {
$( this ).removeClass( "ui-corner-top" ).addClass( "ui-corner-all" );
}
});
});
</script>
</head>
<body id="index" onload="document.getElementById('search').focus()">
#(topmenu)#
#%env/templates/embeddedheader.template%#
::
#%env/templates/simpleheader.template%#
#(/topmenu)#
#(pi)#::
<div style="position:fixed; bottom: 0; right: 1px;"><a href="/Status.html">&pi;</a></div>
#(/pi)#
<h2 class="yacy">
<a href="#[promoteSearchPageGreeting.homepage]#" class="yacylogo"><img src="#[promoteSearchPageGreeting.largeImage]#" alt="yacy" style="margin: auto;"/></a><br /><br />
#[promoteSearchPageGreeting]#
</h2>
<form class="search" action="yacysearch.html" method="get" id="searchform" accept-charset="UTF-8">
<fieldset class="maininput">
<input name="query" class="searchinput" id="search" type="text" size="40" maxlength="80" value="#[former]#" onFocus="this.select()" />
<input type="submit" name="Enter" value="Search" />
<input type="hidden" name="verify" value="#[search.verify]#" />
#(searchdomswitches)#::
<div class="yacysearch">
#(searchtext)#::<input type="radio" id="text" name="contentdom" value="text" #(check)#::checked="checked"#(/check)# /><label for="text">Text</label>&nbsp;&nbsp;#(/searchtext)#
#(searchimage)#::<input type="radio" id="image" name="contentdom" value="image" #(check)#::checked="checked"#(/check)# /><label for="image">Images</label>&nbsp;&nbsp;#(/searchimage)#
#(searchaudio)#::<input type="radio" id="audio" name="contentdom" value="audio" #(check)#::checked="checked"#(/check)# /><label for="audio">Audio</label>&nbsp;&nbsp;#(/searchaudio)#
#(searchvideo)#::<input type="radio" id="video" name="contentdom" value="video" #(check)#::checked="checked"#(/check)# /><label for="video">Video</label>&nbsp;&nbsp;#(/searchvideo)#
#(searchapp)#::<input type="radio" id="app" name="contentdom" value="app" #(check)#::checked="checked"#(/check)# /><label for="app">Applications</label>#(/searchapp)#
</div>
#(/searchdomswitches)#
<input type="hidden" name="nav" value="#[search.navigation]#" />
<input type="hidden" name="startRecord" value="0" />
<input type="hidden" name="resource" value="global" />
<input type="hidden" name="urlmaskfilter" value=".*" />
<input type="hidden" name="prefermaskfilter" value="" />
<input type="hidden" name="indexof" value="off" />
<input type="hidden" name="meanCount" value="5" />
<input type="hidden" name="maximumRecords" value="#[maximumRecords]#" />
#(searchoptions)#::
</fieldset>
<p><a href="/index.html?searchoptions=2" onclick="this.href='/index.html?searchoptions=2&amp;former='+document.getElementById('searchform').search.value+'&amp;contentdom='+radioValue(document.getElementById('searchform').contentdom)">more options...</a></p>
::
</fieldset>
<table>
<tr>
<td><label for="count">Max. number of results</label>:</td>
<td>
<select id="count" name="count">
<option #(count-10)#::selected="selected"#(/count-10)#>10</option>
<option #(count-50)#::selected="selected"#(/count-50)#>50</option>
<option #(count-100)#::selected="selected"#(/count-100)#>100</option>
</select>
</td>
</tr>
<tr>
#(resource-select)#::
<td><label for="resource">Resource</label>:</td>
<td>
<select id="resource" name="resource">
<option value="global" #(global)#::selected="selected"#(/global)#
#(global-disabled)#::disabled="disabled"#(/global-disabled)#>global</option>
<option value="local" #(local)#::selected="selected"#(/local)#>local</option>
</select>
#(global-disabled)#::
Global search is disabled because<br />#(reason)#
<a class="lock" href="ConfigNetwork_p.html">DHT Distribution</a> is::
<a class="lock" href="ConfigNetwork_p.html">Index Receive</a> is::
<a class="lock" href="ConfigNetwork_p.html">DHT Distribution and Index Receive</a> are#(/reason)#
disabled.#(/global-disabled)#
</td>
#(/resource-select)#
</tr>
<tr>
<td><label for="urlmaskfilter">URL mask</label>:</td>
<td>#(urlmaskoptions)#
<input id="urlmaskfilter" name="urlmaskfilter" type="text" size="12" maxlength="80" value="#[urlmaskfilter]#" />
::
<input type="radio" name="urlmask" value="yes" checked /> restrict on <input name="urlmaskfilter" type="text" size="12" maxlength="80" value="#[urlmaskfilter]#" />
<input type="radio" name="urlmask" value="no" /> show all
#(/urlmaskoptions)#
</td>
</tr>
<tr>
<td>
<label for="prefermaskfilter">Prefer mask</label>:
</td>
<td>
#(prefermaskoptions)#
<input id="prefermaskfilter" name="prefermaskfilter" type="text" size="12" maxlength="80" value="#[prefermaskfilter]#" />
::
<input type="radio" name="prefermask" value="yes" checked="checked" /> restrict on <input name="prefermaskfilter" type="text" size="12" maxlength="80" value="#[prefermaskfilter]#" />
<input type="radio" name="prefermask" value="no" /> show all
#(/prefermaskoptions)#
</td>
</tr>
<tr>
<td>
Constraints:
</td>
<td>
<input type="checkbox" id="indexof" name="indexof" #[indexofChecked]# /> <label for="indexof">only index pages</label>
</td>
</tr>
<tr><td></td><td></td></tr>
<tr>
<td>
<a href="http://www.yacy-websuche.de/wiki/index.php/En:SearchParameters">advanced parameters</a>
</td>
<td>
</td>
</tr>
</table>
#(/searchoptions)#
</form>
<script type="text/javascript">
document.getElementById("search").focus();
</script>
#(topmenu)#
#%env/templates/embeddedfooter.template%#
::
#%env/templates/simplefooter.template%#
#(/topmenu)#
<p>
<img src="cytag.png?icon=invisible&amp;nick=yacyh_#[clientid]#&amp;tag=search" alt=""/>
</p>
</body>
</html>