2014-08-27 70 views
0

我有一堆舊URL需要重定向(301)到新的。我只會寫如何重定向(301)一堆舊URL到新的?

Redirect 301 /old-url http://www.example.net/new-url 

爲每一個重定向到.htaccess。但有沒有更好的解決方案,可能使用RewriteMap?

+0

,請您提供一些網址 – 2014-08-27 17:55:59

+0

(有沒有|什麼是)模式? – user2864740 2014-08-27 17:56:23

+0

舊的:http://www.example.net/path新的:http://www.example.net/path-123 – a1277399 2014-08-27 18:00:17

回答

0

一個PHP重定向將工作

這裏www.php.net/manual/en/function.header.php

更多信息

<?php 
header('location:http://www.yoursite.com/whereve'); 
?>