0

これは簡単なはずですが、実際にはそうではありません。

私はこれを達成したい:

  • http:// finaldomain.com /PAGENAME は、使用したい URL です。
  • http:// subdomain.generaldomain .com/index.php?/static-parameter/PAGENAME は、サーバーがページをレンダリングするために必要なものです

htaccess によるミラーリングは、私が探しているものです。リダイレクトではありません。これはできますか?

前もってありがとう、ディーデリク

4

1 に答える 1

0

.htaccessドキュメントルートでこれを試してください。

RewriteEngine on
RewriteBase /

RewriteCond %{HTTP_HOST} ^(www\.)?finaldomain\.com$ [NC]
RewriteRule ^(.*)$ http://subdomain.generaldomain.com/index.php?/static-parameter/$1 [L]

これはリダイレクトします

http://www.finaldomain.com/file.php => to =>
http://subdomain.generaldomain.com/index.php?/static-parameter/file.php

http://finaldomain.com/subfolder/file.php => to =>
http://subdomain.generaldomain.com/index.php?/static-parameter/subfolder/file.php
于 2013-06-19T16:21:28.097 に答える