【发布时间】:2018-05-23 17:40:00
【问题描述】:
我正在使用.htaccess 重写我的子目录或指向单个位置的链接中的其他 URL 信息。我不太清楚如何表达这一点,所以我将在下面提供示例。
OLD URL NEW URLoldsite.com/shop newsite.com/shopoldsite.com/shop/something newsite.com/shopoldsite.com/shop/category/product/123.html newsite.com/shopoldsite.com/shop/landingpage newsite.com/shop
oldsite 仍在执行许多附加功能,因此我只希望 /shop(以及之后的任何内容)重定向到 newsite。
如果在 .htaccess 之外的其他地方更容易做到这一点,那就太好了。
【问题讨论】:
标签: wordpress .htaccess url redirect url-rewriting