diff options
author | yvesf <yvesf-git@xapek.org> | 2010-11-26 19:04:25 +0100 |
---|---|---|
committer | yvesf <yvesf-git@xapek.org> | 2010-11-26 19:04:25 +0100 |
commit | 9122cfed447a643a8c383be5558fd82fc3be7cc7 (patch) | |
tree | de4711d4bddc99815726356b136926e2d7e9714d /templates/_base.html | |
parent | 06b3f727378323089ee56a24999dd97c87887cc0 (diff) | |
download | booksearch-9122cfed447a643a8c383be5558fd82fc3be7cc7.tar.gz booksearch-9122cfed447a643a8c383be5558fd82fc3be7cc7.zip |
prettify
Diffstat (limited to 'templates/_base.html')
-rw-r--r-- | templates/_base.html | 32 |
1 files changed, 19 insertions, 13 deletions
diff --git a/templates/_base.html b/templates/_base.html index ba9e8f2..d6d2010 100644 --- a/templates/_base.html +++ b/templates/_base.html @@ -3,30 +3,36 @@ <head> {% block head %} <link type="text/css" href="{{ url_for("static", filename="style.css") }}" rel="stylesheet" /> - <link type="text/css" href="{{ url_for("static", filename="css/ui-lightness/jquery-ui-1.8.6.custom.css") }}"rel="Stylesheet" /> + <link type="text/css" href="{{ url_for("static", filename="css/smoothness/jquery-ui-1.8.6.custom.css") }}"rel="Stylesheet" /> <script type="text/javascript" src="{{ url_for("static", filename="js/jquery-1.4.2.min.js") }}"></script> <script type="text/javascript" src="{{ url_for("static", filename="js/jquery-ui-1.8.6.custom.min.js") }}"></script> <title>{% block title %}{% endblock %} - booksearch</title> <script> - function start() { - var inputField = document.getElementById("searchInput"); - window.location = "{{ url_for("do_search") }}" + inputField.value; - return false; - } + jQuery(document).ready(function() { + function start() { + var inputField = document.getElementById("searchInput"); + window.location = "{{ url_for("do_search") }}" + inputField.value; + return false; + } + jQuery("#searchInput").bind('keyup', function(evt) { + if (evt.which == 13) + start(); + }); + jQuery("#searchSubmit").click(start); + }); </script> {% block javascript %}{% endblock %} {% endblock %} </head> <body> <div id="header"> - booksearch + <img title="A book is a loaded gun" src="{{ url_for("static", filename="logo.png") }}"/> + <div id="search"> + <input id="searchInput" type="text" value="{% block searchValue %}{% endblock %}" placeholder="terms..." size=40/> + <button id="searchSubmit">Senden</button> + </div> </div> - <div id="search"> - <span class="preSearchField">Search:</span> - <input id="searchInput" type="text" value="{% block searchValue %}{% endblock %}" placeholder="terms..." /> - <button onclick="start()">Senden</button> - </div> - <hr /> + <hr style="clear: both;"/> <div id="content"> {% block content %}{% endblock %} </div> |