一些正則表達式/ htaccess嚮導可以幫助嗎?我在找重寫規則即會.htaccess使用查詢參數重寫代理
- 支持子域
- 通過代理服務器(而不是301)
- 通沿任意數量的查詢參數(如果存在的話)
行爲這樣,這個代理到:
- www.domain.com - > www.otherdomain.com
- dev.domain.com - > dev.otherdomain.com
- www.domain.com?thing=123 - > www.otherdomain.com?thing=123
- dev.domain.com?thing=123 & otherthing = ABC - > dev.otherdomain.com?thing=123 & otherthing = ABC
擁抱
您是否在'www.domain.com'和'dev.domain.com'上啓用了'mod_proxy'? – anubhava
我們有其他的代理規則可以工作。域的DNS解析爲其他域的IP。 – folktrash