Update of /var/cvs/applications/searchrelate/templates In directory james.mmbase.org:/tmp/cvs-serv8070
Modified Files: Searcher.js.jsp Log Message: simplified See also: http://cvs.mmbase.org/viewcvs/applications/searchrelate/templates Index: Searcher.js.jsp =================================================================== RCS file: /var/cvs/applications/searchrelate/templates/Searcher.js.jsp,v retrieving revision 1.25 retrieving revision 1.26 diff -u -b -r1.25 -r1.26 --- Searcher.js.jsp 7 Jul 2008 16:20:42 -0000 1.25 +++ Searcher.js.jsp 7 Jul 2008 16:46:38 -0000 1.26 @@ -13,7 +13,7 @@ * * @author Michiel Meeuwissen - * @version $Id: Searcher.js.jsp,v 1.25 2008/07/07 16:20:42 michiel Exp $ + * @version $Id: Searcher.js.jsp,v 1.26 2008/07/07 16:46:38 michiel Exp $ */ $(document).ready(function(){ @@ -109,26 +109,6 @@ }); }); - // Arrage that pressing enter in the search-area works: - var repository = this.repository; - if (repository != null) { - $(el).find("input.search").keypress(function(ev) { - if (ev.which == 13) { - repository.searcher.search(this.value, 0); - return false; - } - }); - } - var current = this.repository; - if (current != null) { - $(el).find("input.search").keypress(function(ev) { - if (ev.which == 13) { - current.searcher.search(this.value, 0); - return false; - } - }); - } - $(this.repository).find("form.searchform").each(function() { var form = this; form.searcher = searcher; @@ -614,6 +594,13 @@ var self = this; this.logger.debug("binding to "+ $(this.div).find("a.navigate")); + // Arrage that pressing enter in the search-area works: + $(this.div).find("input.search").keypress(function(ev) { + if (ev.which == 13) { + self.search(this.value, 0); + return false; + } + }); $(this.div).find("a.navigate").click(function(ev) { var anchor = ev.target; self.logger.debug("navigating " + anchor); _______________________________________________ Cvs mailing list Cvs@lists.mmbase.org http://lists.mmbase.org/mailman/listinfo/cvs