If you want to rewrite URLs in Apache without a redirect(using internal forwarding) use the P flag at the end as below

http://localhost/foo/1 to http://moo.com/foo/1

RewriteRule /foo/(.*)   http://moo.com/foo/$1 [P]

Advertisements