doc: remove /404.html redirect
Using a root-level /404.html as a redirect to the /latest/404.html causes the URL shown in the browser to change so you can't see what the error-causing URL was. Instead of a redirect, copy the /latest/404.html generated by Sphinx to /404.html and edited with a <base> tag that specifies a base URL for all relative URLs on a page. Signed-off-by: David B. Kinder <david.b.kinder@intel.com>
This commit is contained in:
parent
74edf2e54b
commit
a29ef9178e
|
@ -86,7 +86,7 @@ ifeq ($(RELEASE),latest)
|
|||
cp scripts/publish-README.md $(PUBLISHDIR)/../README.md
|
||||
cp scripts/publish-index.html $(PUBLISHDIR)/../index.html
|
||||
cp scripts/publish-robots.txt $(PUBLISHDIR)/../robots.txt
|
||||
cp scripts/publish-404.html $(PUBLISHDIR)/../404.html
|
||||
sed 's/<head>/<head>\n <base href="https:\/\/projectacrn.github.io\/latest\/">/' $(BUILDDIR)/html/404.html > $(PUBLISHDIR)/../404.html
|
||||
endif
|
||||
cd $(PUBLISHDIR)/..; git add -A; git commit -s -m "publish $(RELEASE)"; git push origin master;
|
||||
|
||||
|
|
|
@ -1,14 +0,0 @@
|
|||
<!DOCTYPE HTML>
|
||||
<html>
|
||||
<head>
|
||||
<title>Page not found in ACRN Hypervisor documentation</title>
|
||||
<meta http-equiv="refresh" content="1; URL=/latest/404.html" />
|
||||
<link rel="canonical" href="/latest/404.html" />
|
||||
<script>
|
||||
window.location.href = "/latest/404.html"
|
||||
</script>
|
||||
</head>
|
||||
<body>
|
||||
<p>Please visit the <a href="/latest/">latest ACRN documentation</a></p>
|
||||
</body>
|
||||
</html>
|
Loading…
Reference in New Issue