【发布时间】:2012-12-19 17:26:42
【问题描述】:
在创建“漂亮”的 URL 时,我的 Apache 配置存在一个小问题。我已经到了输入(或链接)到
的阶段index.html
转发给你
index.php?pageID=Forside
这正是我想要的。 但是我怎样才能让 index.html 留在浏览器的地址栏中呢? 现在它转发并将 URL 更改为原始 URL。
这是我的 .htaccess:
RewriteEngine On
RewriteBase /
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteCond %{REQUEST_URI} index\.html
RewriteRule .* http://www.radoor-designs.dk/index.php?pageID=Forside [L]
在有人使用它之前:缺少选项 +FollowSymLinks,因为它会在 one.com webhotel 上触发错误 500。
提前致谢!
【问题讨论】:
标签: .htaccess seo apache2 url-encoding