dongxiaofa6359 2015-09-25 09:06
浏览 23
已采纳

基于传入域重定向

This might be strange situation, feel free to ask for any clearing up if i don't explain the situation clear enough.

Currently we have a corporate website called www.corporate.com (Wordpress website)

We also have our previous website from the corporation we fused with www.fusedcorporate.com

At the moment when you go to any page on www.fusedcorporate.com you get directed to www.corporate.com

Is there any way in wordpress to check incoming requests if the come from "fusedcorporate.com" and when they do to request to www.corporate.com/fused ?

Another option i'm thinking of is to settle it on a DNS level, but i don't know how to makes calls to a domain redirect to a certain page on a different website.

  • 写回答

1条回答 默认 最新

  • douba1214 2015-09-25 09:20
    关注

    Use a .htaccess file and add the following code

    RewriteEngine On
    RewriteCond %{HTTP_HOST} ^fusedcorporate.com$ [OR]
    RewriteCond %{HTTP_HOST} ^www.fusedcorporate.com$
    RewriteRule (.*)$ http://www.corporate.com/$1 [R=301,L]
    

    Does it solve the problem?

    本回答被题主选为最佳回答 , 对您是否有帮助呢?
    评论

报告相同问题?

悬赏问题

  • ¥15 FLUENT如何实现在堆积颗粒的上表面加载高斯热源
  • ¥30 截图中的mathematics程序转换成matlab
  • ¥15 动力学代码报错,维度不匹配
  • ¥15 Power query添加列问题
  • ¥50 Kubernetes&Fission&Eleasticsearch
  • ¥15 報錯:Person is not mapped,如何解決?
  • ¥15 c++头文件不能识别CDialog
  • ¥15 Excel发现不可读取的内容
  • ¥15 关于#stm32#的问题:CANOpen的PDO同步传输问题
  • ¥20 yolov5自定义Prune报错,如何解决?