From b1256f4800536cd93aec3deccab70e3734b7613e Mon Sep 17 00:00:00 2001 From: Kevin Adams Date: Thu, 9 Oct 2014 14:59:06 -0700 Subject: [PATCH] changed to use jQuery text method --- source/javascripts/app/search.js | 18 ++---------------- 1 file changed, 2 insertions(+), 16 deletions(-) diff --git a/source/javascripts/app/search.js b/source/javascripts/app/search.js index a7ed873..8c527c7 100644 --- a/source/javascripts/app/search.js +++ b/source/javascripts/app/search.js @@ -53,7 +53,8 @@ }); highlight.call(this); } else { - searchResults.html('
  • No Results Found for "' + this.value.escapeHTML() + '"
  • '); + searchResults.html('
  • '); + $('.search-results li').text('No Results Found for "' + this.value + '"'); } } else { unhighlight(); @@ -69,19 +70,4 @@ content.unhighlight(highlightOpts); } - var __entityMap = { - "&": "&", - "<": "<", - ">": ">", - '"': '"', - "'": ''', - "/": '/' - }; - - String.prototype.escapeHTML = function() { - return String(this).replace(/[&<>"'\/]/g, function (s) { - return __entityMap[s]; - }); - } - })(window);