Created
July 6, 2012 14:52
-
-
Save jlong/3060618 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
diff --git a/source/docs/index.html b/source/docs/index.html | |
index da07196..e81e6ac 100644 | |
--- a/source/docs/index.html | |
+++ b/source/docs/index.html | |
@@ -45,7 +45,7 @@ sidebar: false | |
$('.articles li').each(function() { | |
var li = $(this), a = li.find('a'); | |
- if (expression.test(li.text()) || expression.test(a.attr('data-search-meta'))) { | |
+ if ((li.text().search(expression) > -1) || (('' + a.attr('data-search-meta')).search(expression) > -1)) { | |
a.html(a.text().replace(expression, "<mark>$1</mark>")); | |
li.show(); | |
results = true; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment