diff --git a/public/src/forum/admin/footer.js b/public/src/forum/admin/footer.js index 2057af138c..9459ab2b06 100644 --- a/public/src/forum/admin/footer.js +++ b/public/src/forum/admin/footer.js @@ -9,8 +9,10 @@ define('forum/admin/footer', ['forum/admin/settings'], function(Settings) { acpIndex = data; for (var file in acpIndex) { if (acpIndex.hasOwnProperty(file)) { - acpIndex[file] = acpIndex[file].replace(//g, ''); - acpIndex[file] = $(acpIndex[file]).text().toLowerCase(); + acpIndex[file] = $('
' + acpIndex[file] + '
'); + acpIndex[file].find('ul.nav, script').remove(); + + acpIndex[file] = acpIndex[file].text().toLowerCase().replace(/[ |\r|\n]+/g, ' '); } } @@ -37,7 +39,7 @@ define('forum/admin/footer', ['forum/admin/settings'], function(Settings) { if (position !== -1) { var href = file.replace('.tpl', ''), title = href.replace(/^\/admin\//, '').split('/'), - description = acpIndex[file].substring(Math.max(0, position - 15), Math.min(acpIndex[file].length - 1, position + 15)) + description = acpIndex[file].substring(Math.max(0, position - 25), Math.min(acpIndex[file].length - 1, position + 25)) .replace(value, '' + value + ''); for (var t in title) {