From 8fb60f319079782886357c66ef6b925b4598108c Mon Sep 17 00:00:00 2001 From: anonfagola Date: Fri, 14 Aug 2015 16:56:19 -0700 Subject: [PATCH] Added auto title HTML decoder As per https://github.com/ctrlcctrlv/infinity/issues/518 This should automatically be done by PHP, but for now, here's a dirty fix. --- js/decode-title.js | 7 +++++++ 1 file changed, 7 insertions(+) create mode 100644 js/decode-title.js diff --git a/js/decode-title.js b/js/decode-title.js new file mode 100644 index 000000000..7a70b7742 --- /dev/null +++ b/js/decode-title.js @@ -0,0 +1,7 @@ +function decodeEntities(encodedString) { + var textArea = document.createElement('textarea'); + textArea.innerHTML = encodedString; + return textArea.value; +} + +$("title").text(decodeEntities($("title").text()));