gkimball/php301mapper

There is no license information available for the latest version (1.0) of this package.

Maps an array of key val pairs to 301 redirects

1.0 2017-02-23 00:12 UTC

This package is not auto-updated.

Last update: 2024-05-20 14:03:35 UTC


README

Include the Php301Mapper class to your header file. Add the following to the top of your 404 loader page.

$redirects = [
    '/index.php?page1OLD' => '/index.php?page1NEW',
    '/index.php?page2OLD' => '/index.php?page2NEW',
    '/index.php?page3OLD' => '/index.php?page2NEW',
];

MapFactory::Mapper($_SERVER['REQUEST_URI'],$redirects)->run();

Dev Installation

composer install