Skip to content

Commit

Permalink
Merge pull request #137 from chillu/pulls/redirect-contributing
Browse files Browse the repository at this point in the history
Auto-redirect /contributing to current master docs (fixes #121)
  • Loading branch information
Damian Mooyman authored Jun 9, 2016
2 parents c891838 + 5abf266 commit 0a9cbd5
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions .htaccess
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,10 @@ ErrorDocument 500 /assets/error-500.html
RewriteCond %{REQUEST_URI} ^/?framework/en/
RewriteRule ^framework/en/(.*)$ /en/$1 [R=301,NC,QSA,L]

# Docs in /contributing are version agnostic, and should always point to latest
RewriteCond %{REQUEST_URI} !(4.0)
RewriteRule ^(.*)/(.*)/contributing/?(.*)?$ /$1/4.0/contributing/$3 [R=301,L]

# DokuWiki rewrite rules: Need to happen before other rules in order to redirect /doku.php?id=<pagename>
# to /pagename, which can then be matched by the legacy rewrite rules further down
RewriteCond %{QUERY_STRING} ^(\bid\b=([^&]*)&?(.*)?)
Expand Down

0 comments on commit 0a9cbd5

Please sign in to comment.