From d0e8ad791d78bdeb179ce6d0107f45ad59c37d2c Mon Sep 17 00:00:00 2001 From: Menci Date: Sun, 23 Apr 2017 16:22:40 +0800 Subject: [PATCH] Remove in ranklist user infomation --- views/index.ejs | 2 ++ views/ranklist.ejs | 2 ++ 2 files changed, 4 insertions(+) diff --git a/views/index.ejs b/views/index.ejs index dbd895e..9436762 100644 --- a/views/index.ejs +++ b/views/index.ejs @@ -48,6 +48,8 @@ var elem = document.createElement('div'); elem.style = 'max-height: 50px; overflow: hidden; width: 100%; max-width: 480px; '; elem.innerHTML = html; + var imgs = Array.from(elem.getElementsByTagName('img')); + for (var i in imgs) imgs[i].parentNode.removeChild(imgs[i]); var script = document.getElementById('user-infomation-script-<%= i %>'); script.parentNode.replaceChild(elem, script); })(); diff --git a/views/ranklist.ejs b/views/ranklist.ejs index ae48d7f..ed0378a 100644 --- a/views/ranklist.ejs +++ b/views/ranklist.ejs @@ -32,6 +32,8 @@ var elem = document.createElement('div'); elem.style = 'max-height: 50px; overflow: hidden; width: 100%; max-width: 840px; '; elem.innerHTML = html; + var imgs = Array.from(elem.getElementsByTagName('img')); + for (var i in imgs) imgs[i].parentNode.removeChild(imgs[i]); var script = document.getElementById('user-infomation-script-<%= i %>'); script.parentNode.replaceChild(elem, script); })();