Commit b1256f48 authored by Kevin Adams's avatar Kevin Adams

changed to use jQuery text method

parent b40b3b47
...@@ -53,7 +53,8 @@ ...@@ -53,7 +53,8 @@
}); });
highlight.call(this); highlight.call(this);
} else { } else {
searchResults.html('<li>No Results Found for "' + this.value.escapeHTML() + '"</li>'); searchResults.html('<li></li>');
$('.search-results li').text('No Results Found for "' + this.value + '"');
} }
} else { } else {
unhighlight(); unhighlight();
...@@ -69,19 +70,4 @@ ...@@ -69,19 +70,4 @@
content.unhighlight(highlightOpts); content.unhighlight(highlightOpts);
} }
var __entityMap = {
"&": "&amp;",
"<": "&lt;",
">": "&gt;",
'"': '&quot;',
"'": '&#39;',
"/": '&#x2F;'
};
String.prototype.escapeHTML = function() {
return String(this).replace(/[&<>"'\/]/g, function (s) {
return __entityMap[s];
});
}
})(window); })(window);
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment