Commit 9fea3bc4 authored by Davis King's avatar Davis King

Added a 301 redirect to the main page using php. Now everything should

always look like it's at dlib.net

--HG--
extra : convert_revision : svn%3Afdd8eb12-d10e-0410-9acb-85c331704f74/trunk%403377
parent b82b223b
...@@ -162,6 +162,12 @@ makedocs () ...@@ -162,6 +162,12 @@ makedocs ()
echo Generating sitemap echo Generating sitemap
cd docs/web || report_failure cd docs/web || report_failure
find . -name "*.html" | awk '{ print "http://dclib.sourceforge.net" substr($1,2)}' > sitemap.txt find . -name "*.html" | awk '{ print "http://dclib.sourceforge.net" substr($1,2)}' > sitemap.txt
# make the main index have a 301 redirect. Use php to do this
echo '<?php if ($_SERVER["SERVER_NAME"] != "dlib.net") { header("Location: http://dlib.net/", true, 301); exit; } ?>' > index.php
cat index.html >> index.php
rm index.html
cd ../.. cd ../..
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment