Javascript
We have prepared methods you can use to manipulate behaviour of the search.
Jquery search plugin
The Javascript Search Object is saved on the JQuery Object. To get it, you can use $(".search-result-box").search().
If you want to change the behaviour, before showing, after showing, before hiding or after hiding you can use the following methods:
- beforeShow()
- afterShow()
- beforeHide()
- afterHide()
Example
Here is an example where we put a class on the header while searching.
var header = $("search-result-box"); $(this).search().beforeShow(function() { header.addClass("searching"); }); $("search-result-box").search().afterHide(function() { header.removeClass("searching"); })