Answer the question
In order to leave comments, you need to log in
How to use mod_rewrite to replace files from one url with another without redirecting?
Solution: https://httpd.apache.org/docs/2.4/rewrite/proxy.html
There is a domain1 and domain2 domain
On the hosting they look like this:
/public_html (root of domain1)
/public_html/domain2 (root of domain2)
Actually mod_rewrite is lying at the root of domain2:
Options +FollowSymLinks
RewriteEngine On
RewriteRule ^shared/portfolio_html/(.*)$
domain2 /shared/portfolio_html/$1 [L]
There shouldn't be an explicit redirect.
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question