Search code examples
urlhttp-redirectmediawikiwiki

MediaWiki - How to do a hard redirect?


I need to redirect to another article, as soon as i get to a page. In other words: the URL needs to change to the original article. How do i do that?

www.myWiki.org/RD

should e.g. jump to

www.myWiki.org/redirect

As soon as the user gets there.


Solution

  • On the Page [[RD]] write this:

    #REDIRECT [[redirect]]
    

    And than www.myWiki.org/RD gets hard redirected to www.myWiki.org/redirect.

    This works on current Mediawiki versions, in older versions you will get a soft redirect. More on mediawiki.org Help:Redirects