Apache reverse proxy cannot load jscssimg reverse proxy configuration {code ...} on the webpage after reverse proxy, I set roadcloud reverse proxy to the first-level directory of www.roadcloud.com.cn, www.roadcloud.com.cn TO BE proxy, but the second-level directory and the following cannot be proxy...
Apache reverse proxy cannot load js css img
Reverse proxy configuration
Order deny,allow Allow from all
ProxyPass /roadcloud/ http://www.roadcloud.com.cn/ ProxyPassReverse /roadcloud/ http://www.roadcloud.com.cn/
Web page after reverse proxy
I have set/roadcloud reverse proxy to www.roadcloud.com.cn,
The first-level directory of www.roadcloud.com.cn can be proxy, but the second-level directory and the following cannot be proxy, such
My domain name is www.mcmxzl.com
AGENT: http://www.roadcloud.com.cn/templates/index/default/images/slider_1.jpg
The post-proxy link should be: https://www.mcmxzl.com/roadcloud/templates/index/default/images/slider_1.jpg
But it is: https://www.mcmxzl.com/templates/index/default/images/slider_1.jpg
Reply content:
Apache reverse proxy cannot load js css img
Reverse proxy configuration
Order deny,allow Allow from all
ProxyPass /roadcloud/ http://www.roadcloud.com.cn/ ProxyPassReverse /roadcloud/ http://www.roadcloud.com.cn/
Web page after reverse proxy
I have set/roadcloud reverse proxy to www.roadcloud.com.cn,
The first-level directory of www.roadcloud.com.cn can be proxy, but the second-level directory and the following cannot be proxy, such
My domain name is www.mcmxzl.com
AGENT: http://www.roadcloud.com.cn/templates/index/default/images/slider_1.jpg
The post-proxy link should be: https://www.mcmxzl.com/roadcloud/templates/index/default/images/slider_1.jpg
But it is: https://www.mcmxzl.com/templates/index/default/images/slider_1.jpg
Your goal should be to make http://www.mcmxzl.com/roadcloud/Proxy http://www.roadcloud.com.cn/
The problem is that directly writing this reverse proxy will bring the original path, that is to say, your current situation is that you directly access the http://www.mcmxzl.com/roadcloud/templates/The obtained signature is/This is the result of http://www.roadcloud.com.cn/templates? This is the same as nginx. If you want apache to automatically remove/roadcloud, You need to rewrite the url. apache does not know much about it and you can search for one. Let's take a look.
Https://segmentfault.com/a/1190000000406581
I have set/roadcloud reverse proxy to www.roadcloud.com.cn,
The first-level directory of www.roadcloud.com.cn can be proxy, but the second-level directory and the following cannot be proxy, such
My domain name is www.mcmxzl.com
AGENT: http://www.roadcloud.com.cn/templates/index/default/images/slider_1.jpg
The post-proxy link should be: https://www.mcmxzl.com/roadcloud/templates/index/default/images/slider_1.jpg
But it is: https://www.mcmxzl.com/templates/index/default/images/slider_1.jpg