我的.htaccess文件中有以下内容,可以正常工作,除了当我点击时:
http://bunkerbuster.com/profiles/1
地址栏中的 URL 将替换为新 URL。我不希望这种情况发生,我希望 URL 仍然显示 bunkerbuster.com
感谢您的帮助。
Options +FollowSymLinks
RewriteEngine On
RewriteBase /
RewriteRule ^profiles/([0-9]+)$ http://projectzebra-bunkerbuster.herokuapp.com/profiles/$1 [R,L]
RewriteRule ^profiles/([0-9]+)/$ http://projectzebra-bunkerbuster.herokuapp.com/profiles/$1 [R,L]
你似乎在尝试让Apache充当代理。
这不能使用 htaccess 完成,但可以使用 mod_proxy 完成:
http://httpd.apache.org/docs/2.0/mod/mod_proxy.html#proxypass