【发布时间】:2011-04-26 15:27:34
【问题描述】:
看在上帝的份上,我似乎无法让这个 mod_rewrite 正常工作。让我在这里问,而不是进行蛮力试错。
- 我希望 mod_rewrite 规则适用于所有域。
- 我想要 httpd.conf 中的 mod_rewrite 条目
-
我想摆脱这个 WWW 病毒(出于 SEO 目的):
-
我想摆脱 index.html(对于 SEO,谷歌索引它而不仅仅是域):
http://www.example.com/index.html > http://example.com
http://www.example.com/some/index.html > http://example.com/some/index.html
域位于<virtualhost> 条目中。我不知道在哪里放置什么或哪个应该优先。正如我所提到的,我想将这两条规则应用于服务器中的所有域。
ssl.conf 加剧了这种情况。所有这些都需要输入 ssl.conf 吗?当有 2 个重定向时会发生什么,例如:
http://www.example.com/index.html > http://example.com/index.html > http://example.com
非常感谢。这很快就变得如此令人困惑。
玛丽亚
【问题讨论】:
标签: apache mod-rewrite