在这种情况下我需要帮助
我需要重定向(301)子域test.example.com/?preview_theme=niss-promag
到https://example.com
而没有/?preview_theme=niss-promag
我已经使用过代码,但是它使用相同的路径https://example.com/?preview_theme=niss-promag
重定向到根域>
这是当前使用的代码:
RewriteEngine on RewriteCond %{HTTP_HOST} ^test.example.com$ RewriteRule ^(.*)$ https://example.com [L,R=301]
注意:我需要将子域的任何路径重定向到我未指定的根域!
我需要在这种情况下提供帮助,我需要将(301)子域test.example.com/?preview_theme=niss-promag重定向(https)到https://example.com,而无需/?preview_theme = niss-promag我已经使用过代码,但是这是...
这应该起作用: