디버깅 및 개발을 위해 대부분의 PHP 웹 사이트를 로컬 컴퓨터에 복사했습니다. 원본 원격 웹 사이트에는 전송할 수없는 많은 수의 이미지가 있습니다. 내가 /etc/hosts
에 127.0.0.1
에 매핑 first_domain.com
으로 가야하고 끌어 아파치 (최신, 최고의 버전)을 구성 할 수 있도록 동일한 이미지는 동일한 서버에 두 개의 서로 다른 도메인 이름가 제공하는 /images/*/*
/etc/hosts
가 쉬웠다 구성 second_domain.com/images/*/*
아파치가 URL을 다른 서버에 전달하는 방법
에서 . 하지만 아파치 설정에서 내가 뭘 잘못하고 있는지 모르겠다.
ProxyRequests Off
ProxyPass /properties/ http://newhawaiiproperties.com/properties/
<Location /properties/>
ProxyPassReverse/
ProxyHTMLEnable On
ProxyHTMLURLMap http://newhawaiiproperties.com/properties/ /properties/
ProxyHTMLURLMap//properties/
</Location>
내가 ProxyRequests On
-ProxyRequests Off
을 변경해야합니다 : 기본값 이외에 conf/extra/proxy-html.conf
에서
LoadModule proxy_module modules/mod_proxy.so
LoadModule proxy_http_module modules/mod_proxy_http.so
LoadModule rewrite_module modules/mod_rewrite.so
#...
# Configure mod_proxy_html to understand HTML4/XHTML1
<IfModule proxy_html_module>
Include conf/extra/proxy-html.conf
</IfModule>
?
업데이트 : 나는 HTML 파일을 변경할 필요가 없다는 것을 깨닫고있다. 그래서 그들은 ProxyHTML...
을 제거 할 수 있어야한다.