title: .htaccess rewrite proxy with query params
body: <p>Can some regex/htaccess wizard help? I'm looking for the rewrite rule that will</p>
  
  <ul>
  <li>support sub domains</li>
  <li>act via proxy (not a 301)</li>
  <li>pass along any number of query parameters (if present)</li>
  </ul>
  
  <p>Such that, this proxies to that:</p>
  
  <ul>
  <li>www.domain.com -> www.otherdomain.com</li>
  <li>dev.domain.com -> dev.otherdomain.com</li>
  <li>www.domain.com?thing=123 -> www.otherdomain.com?thing=123</li>
  <li>dev.domain.com?thing=123&amp;otherthing=abc ->
  dev.otherdomain.com?thing=123&amp;otherthing=abc</li>
  </ul>
  
  <p><em>hugs</em></p>