We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 31902
    • 342 Posts
    Willi Waizenegger Reply #1, 15 years ago
    I need to have a single page re-direct to another one on a site. Using a simple .htaccess file doesn't seem to work, for some reason. In the .htaccess file, I've tried different variations of this:

    Redirect /index.php?a=61 http://www.example.com/index.php?a=62

    ...and placing that in the root. It doesn't work.

    What am I supposed to be doing?

    I thought I read somewhere there is a snippet or something called 'Redirector' to do this stuff but all the links to it don't seem to function.

    Any ideas? Thank you in advance.

    Revo 2.1.3
    PHP Version 5.2.10
      • 3749
      • 24,544 Posts
      You could make the page a weblink that points to the other page.

      You could also put a redirecting meta tag in the <head> section of that page. (sorry, the forum won't let me post the code for it).

      Or you could do it with a simple snippet (I had to mangle the code a little to keep the forum software from trashing it):

      <?php
      $url = 'htp://ur-l-of-other-page';
      $modx -> sendRedirect($url);
      [ed. note: BobRay last edited this post 15 years ago.]
        Did I help you? Buy me a beer
        Get my Book: MODX:The Official Guide
        MODX info for everyone: http://bobsguides.com/modx.html
        My MODX Extras
        Bob's Guides is now hosted at A2 MODX Hosting