This commit is contained in:
pw3t 2014-01-17 20:32:38 +01:00
commit a62b94e21c
7 changed files with 79 additions and 32 deletions

View File

@ -22,6 +22,10 @@ engine = duckduckgo_definitions
engine = duckduckgo engine = duckduckgo
locale = en-us locale = en-us
[filecrop]
engine = filecrop
categories = files
[flickr] [flickr]
engine = flickr engine = flickr
categories = images categories = images
@ -44,7 +48,7 @@ categories = images
[piratebay] [piratebay]
engine = piratebay engine = piratebay
categories = videos, music categories = videos, music, files
[soundcloud] [soundcloud]
engine = soundcloud engine = soundcloud

View File

@ -9,6 +9,7 @@ url = 'https://thepiratebay.se/'
search_url = url + 'search/{search_term}/0/99/{search_type}' search_url = url + 'search/{search_term}/0/99/{search_type}'
search_types = {'videos': '200' search_types = {'videos': '200'
,'music' : '100' ,'music' : '100'
,'files' : '0'
} }
def request(query, params): def request(query, params):

View File

@ -25,7 +25,16 @@ body, #container {
.row p { padding: 0 10px; max-width: 700px; } .row p { padding: 0 10px; max-width: 700px; }
.row h3,ul { margin: 4px 8px;} .row h3,ul { margin: 4px 8px;}
.hmarg { margin: 0 20px; } .hmarg {
margin: 0 20px;
border: 1px solid #3498DB;
padding: 4px 10px;
}
a:link.hmarg { color: #3498DB; }
a:visited.hmarg { color: #3498DB; }
a:active.hmarg { color: #3498DB; }
a:hover.hmarg { color: #3498DB; }
.top_margin { margin-top: 60px; } .top_margin { margin-top: 60px; }
@ -113,9 +122,7 @@ tr:hover td { background: #DDDDDD; }
.center #search_wrapper { margin-left: auto; margin-right: auto; } .center #search_wrapper { margin-left: auto; margin-right: auto; }
.q { .q {
background: none repeat scroll 0 0 #FFFFFF; background: none repeat scroll 0 0 #FFFFFF;
border: 1px solid #8D8D8D; border: 1px solid #3498DB;
border-radius: 3px;
box-shadow: 1px 1px 2px #999999 inset;
color: #222222; color: #222222;
font-size: 16px; font-size: 16px;
height: 28px; height: 28px;

Binary file not shown.

Before

Width:  |  Height:  |  Size: 34 KiB

After

Width:  |  Height:  |  Size: 7.5 KiB

View File

@ -4,49 +4,52 @@
<div class="row"> <div class="row">
<h1>About <a href="/">searx</a></h1> <h1>About <a href="/">searx</a></h1>
<p>Searx is a <a href="https://en.wikipedia.org/wiki/Metasearch_engine">metasearch engine</a> inspired by the <a href="http://seeks-project.info/">seeks-project</a>. <p>Searx is a <a href="https://en.wikipedia.org/wiki/Metasearch_engine">metasearch engine</a>, aggregating the results of other <a href="/engines">search engines</a> while not storing information about its users.
<br />It tries to provide basic privacy by mixing your queries with those from others while avoiding storing search data. For all browsers (except chrom*) queries are made using a POST request. Thus they don't show up in our logs, nor in your url history. For Chrom* users there is an exception, searx is used from the search bar, it issues GET requests.
<br />You can add it to your browsers search bar and even make it your default search engine.
</p> </p>
<h2>What makes searx different</h2> <h2>Why use Searx?</h2>
<ul> <ul>
<li>No ads - searx is Free Software (free-as-in-freedom), funded by your donations</li> <li>Maybe Searx wont offer you as personalised results as Google, but it doesn't make a profile about you</li>
<li>Privacy - tries to minimalize the digital footprint of the searches</li> <li>Searx doesn't care about what you search, never shares anything with a third party, and it can't be used to compromise you</li>
<li>Optionally self hosted - see the <a href="#faq">FAQ</a></li> <li>Searx doesn't make money on ads and it isn't customised based on your interests. You get the pure search results</li>
<li>Easy to add new engines/categories</li> <li>Searx is a free software, the code is 100% open and you can help to make it better. See more on <a href="https://gmail.com/asciimoo/searx">github</a></li>
</ul> </ul>
<p>If you do care about privacy, want to be a conscious user, moreover believe
in digital freedom, make Searx your default search engine or run it on your own server</p>
<h2>Engines</h2> <h2>Technical details - How does it work?</h2>
{% for (categ,search_engines) in categs %} <p>Searx is a <a href="https://en.wikipedia.org/wiki/Metasearch_engine">metasearch engine</a>,
<h3>{{ categ.capitalize() }}</h3> inspired by the <a href="http://seeks-project.info/">seeks project</a>.<br />
<ul> It provides basic privacy by mixing your queries with searches on other platforms without storing search data. Queries are made using a POST request on every browser (except chrome*). Therefore they don't show up in our logs, neither in your url history. In case of Chrome* users there is an exception, Searx uses the search bar to perform GET requests.<br />
{% for search_engine in search_engines %} Searx can be added to your browser's search bar, moreover it can be set as the default search engine.
{% if not search_engine.private %} </p>
<li>{{ search_engine.name }}</li>
{% endif %}
{% endfor %}
</ul>
{% endfor %}
<p>Please add more engines to this list, pull requests are welcome!</p>
<h2><a href="https://github.com/asciimoo/searx/wiki/Searx-instances">Running public instances</a></h2> <h2>How can I have my own?</h2>
<p>Searx appreciates your suspicion regarding logs, so take the <a href="https://github.com/asciimoo/searx">code</a> and run it yourself! <br />Add your Searx to this <a href="https://github.com/asciimoo/searx/wiki/Searx-instances">list</a> to help other people to have privacy and make the Internet freer!
<br />The more decentralized the Internet is the more freedom we have!</p>
<hr />
<h2 id="faq">FAQ</h2> <h2 id="faq">FAQ</h2>
<h3>Trust</h3>
<p>It's ok if you don't trust us regarding the logs, <a href="https://github.com/asciimoo/searx">take the code</a> and run it yourself! decentralize!</p>
<h3>How to add to firefox?</h3> <h3>How to add to firefox?</h3>
<p><a href="#" onclick="window.external.AddSearchProvider(window.location.protocol + '//' + window.location.host + '/opensearch.xml')">Install</a> searx as a search engine on any version of Firefox! (javascript required)</p> <p><a href="#" onclick="window.external.AddSearchProvider(window.location.protocol + '//' + window.location.host + '/opensearch.xml')">Install</a> searx as a search engine on any version of Firefox! (javascript required)</p>
<h2 id="dev_faq">Developer FAQ</h2> <h2 id="dev_faq">Developer FAQ</h2>
<h3>New engines?</h3> <h3>New engines?</h3>
<ul> <ul>
<li>Edit your engines.cfg, see <a href="https://raw.github.com/asciimoo/searx/master/engines.cfg_sample">sample config</a></li> <li>Edit your engines.cfg, see <a href="https://raw.github.com/asciimoo/searx/master/engines.cfg_sample">sample config</a></li>
<li>Create your custom engine module, check the <a href="https://github.com/asciimoo/searx/blob/master/examples/basic_engine.py">example engine</a></li> <li>Create your custom engine module, check the <a href="https://github.com/asciimoo/searx/blob/master/examples/basic_engine.py">example engine</a></li>
</ul> </ul>
<p>Don't forget to restart searx after config edit!</p> <p>Don't forget to restart searx after config edit!</p>
<h3>WSGI support?</h3>
<p><a href="https://about.okhin.fr/posts/Searx/">Okhin wrote</a> a great and detailed article about the setup.</p> <h3>Installation/WSGI support?</h3>
<p>See the <a href="https://github.com/asciimoo/searx/wiki/Installation">installation and setup</a> wiki page</p>
<h3>How to debug engines?</h3> <h3>How to debug engines?</h3>
<p><a href="/stats">Stats page</a> contains some useful data about the used engines.</p> <p><a href="/stats">Stats page</a> contains some useful data about the used engines.</p>
</div> </div>
{% endblock %} {% endblock %}

View File

@ -0,0 +1,26 @@
{% extends 'base.html' %}
{% block content %}
<div class="row">
<h2>Currently used search engines</h2>
<table style="width: 80%;">
<tr>
<th>Engine name</th>
<th>Category</th>
</tr>
{% for (categ,search_engines) in categs %}
{% for search_engine in search_engines %}
{% if not search_engine.private %}
<tr>
<td>{{ search_engine.name }}</td>
<td>{{ categ }}</td>
</tr>
{% endif %}
{% endfor %}
{% endfor %}
</table>
<p>Please add more engines to this list, pull requests are welcome!</p>
<p class="right"><a href="/">back</a></p>
</div>
{% endblock %}

View File

@ -70,7 +70,8 @@ def get_base_url():
def render(template_name, **kwargs): def render(template_name, **kwargs):
global categories global categories
kwargs['categories'] = sorted(categories.keys()) kwargs['categories'] = ['general']
kwargs['categories'].extend(x for x in sorted(categories.keys()) if x != 'general')
if not 'selected_categories' in kwargs: if not 'selected_categories' in kwargs:
kwargs['selected_categories'] = [] kwargs['selected_categories'] = []
cookie_categories = request.cookies.get('categories', '').split(',') cookie_categories = request.cookies.get('categories', '').split(',')
@ -183,8 +184,13 @@ def index():
@app.route('/about', methods=['GET']) @app.route('/about', methods=['GET'])
def about(): def about():
return render('about.html')
@app.route('/engines', methods=['GET'])
def list_engines():
global categories global categories
return render('about.html', categs=categories.items()) return render('engines.html', categs=categories.items())
@app.route('/preferences', methods=['GET', 'POST']) @app.route('/preferences', methods=['GET', 'POST'])