summaryrefslogtreecommitdiff
path: root/help3xsl/help2.js
diff options
context:
space:
mode:
authorOlivier Hallot <olivier.hallot@libreoffice.org>2020-06-15 16:51:34 -0300
committerOlivier Hallot <olivier.hallot@libreoffice.org>2020-06-17 01:32:48 +0200
commit456d9b054d29362667b0f3acc391c46293312751 (patch)
tree8d6fc1f05a2a940d49a9ca1cdd9770442086d6e8 /help3xsl/help2.js
parent01bf38a8fe1221235a2b32cc5773c49e1228a418 (diff)
Add better 404 error
Missing help pages or links with bad HID were redirected to module entry page, masking the real issue in Help. This patch activated the 404 page and add HID information for debug and fix. Change-Id: I0d55f1c36d9a6c3fab0096d5e3cd171087729691 Reviewed-on: https://gerrit.libreoffice.org/c/help/+/96401 Tested-by: Jenkins Reviewed-by: Olivier Hallot <olivier.hallot@libreoffice.org>
Diffstat (limited to 'help3xsl/help2.js')
-rw-r--r--help3xsl/help2.js5
1 files changed, 4 insertions, 1 deletions
diff --git a/help3xsl/help2.js b/help3xsl/help2.js
index 95635c8465..f40492afb1 100644
--- a/help3xsl/help2.js
+++ b/help3xsl/help2.js
@@ -232,9 +232,12 @@ if (document.body.getElementsByTagName('meta')) {
}
var module = getParameterByName("DbPAR");
-var helpID = getParameterByName("HID");
fixURL(module,system);
moduleColor(module);
+var helpID = getParameterByName("HID");
+// only used in xhp pages with <help-id-missing/> tags
+var missingElement = document.getElementById("bm_HID2");
+if(missingElement != null){missingElement.innerHTML = helpID;}
function debugInfo(dbg) {
if (dbg == null) return;