Skip to content

Commit

Permalink
clear search field after submit
Browse files Browse the repository at this point in the history
  • Loading branch information
kraih committed Oct 27, 2013
1 parent 24af3a5 commit 7e84891
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions lib/Mojolicious/templates/mojobar.html.ep
Expand Up @@ -68,6 +68,11 @@
</div>
</div>
%= javascript begin
$('#mojobar-links form').submit(function (e) {
e.preventDefault();
this.submit();
$('#mojobar-links input[type="search"]').val('');
});
$(window).load(function () {
if (window.location.hash) {
var tweak = $(window.location.hash).offset().top - 50;
Expand Down

0 comments on commit 7e84891

Please sign in to comment.