【发布时间】:2015-06-18 15:23:56
【问题描述】:
我正在尝试编写重定向表单网址的重定向规则:
http://example.com/?lang=fr/hub/anypagehere => http://example.com/hub/anypagehere/?lang=fr
仅当 url 中有“hub”时。
有没有办法用 .htaccess 做到这一点?
【问题讨论】:
-
正则表达式?
-
是的,有。看看simonecarletti.com/blog/2009/01/apache-query-string-redirects。我现在没有时间回答这个问题,但是如果没有人提供解决方案,我会稍后回来回答。
标签: php .htaccess redirect url-redirection