You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@httpd.apache.org by Errol Neal <en...@dfi-intl.com> on 2006/08/01 18:24:56 UTC

[users@httpd] URL Rewriting with proxy-html

I'm having trouble getting proxy-html to behave the way I want it to.
It's rewriting comments and touching parts of the html that permit our
flash stuff to work..

<VirtualHost 172.16.101.119:80>
        ServerAdmin netop@dfi-intl.com
        DocumentRoot /var/www/proxy1/wwwroot
        CustomLog "|/usr/local/sbin/cronolog
/var/www/proxy1_dfi-intl_com/logs/%Y-%m-%d-proxy1_dfi-intl_com.log"
combined
        ProxyRequests Off
        ProxyHTMLLogVerbose On
        #ProxyHTMLStripComments On
        ProxyPass /usaf/ http://172.16.103.200/
        ProxyHTMLURLMap http://172.16.103.200/ /usaf
        <Location /usaf>
            ProxyPassReverse /
            #ProxyHTMLStripComments On
            SetOutputFilter proxy-html
            
            ProxyHTMLURLMap / /usaf/	
            ProxyHTMLURLMap /usaf/ /usaf
            ProxyHTMLMeta on
            ProxyHTMLFixups on
            ProxyHTMLLogVerbose On
            ProxyHTMLExtended on
            ProxyHTMLStripComments On
            RequestHeader unset Accept-Encoding
        </Location>

</VirtualHost>

So for a example, "application/x-shockwave-flash" ends up as
"application/usaf/x-shockwave-flash" and a comment
"// Visual basic helper required to detect Flash Player ActiveX control
version information" is rewritten as 
" /usaf//usaf/ Visual basic helper required to detect Flash Player
ActiveX control version information". It also seems as if some recursive
behavior has been introduced, but only for the comments. Any helps/hints
are much apprecited. 
__________________________________________
Errol Uriel Neal Jr.
Sr. Network Administrator
DFI International, Inc.
1717 Pennsylvania Ave NW, Suite 1300
Washington, DC  20006
Tel (202)452-6955
Fax (202)452-6910
eneal@dfi-intl.com
www.dfi-intl.com


---------------------------------------------------------------------
The official User-To-User support forum of the Apache HTTP Server Project.
See <URL:http://httpd.apache.org/userslist.html> for more info.
To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
   "   from the digest: users-digest-unsubscribe@httpd.apache.org
For additional commands, e-mail: users-help@httpd.apache.org


Re: [users@httpd] URL Rewriting with proxy-html

Posted by Nick Kew <ni...@webthing.com>.
On Tuesday 01 August 2006 17:24, Errol Neal wrote:
>
>             ProxyHTMLURLMap / /usaf/
>             ProxyHTMLExtended on

That combination is bad news, for the reasons you've seen.

You can stop it applying that rule to your scripts using the
flags to ProxyHTMLURLMap.  If you need to rewrite URLs within
your scripts, you'll need a more specific search pattern in there.

Do you really need every proxy-html option turned on?

-- 
Nick Kew

---------------------------------------------------------------------
The official User-To-User support forum of the Apache HTTP Server Project.
See <URL:http://httpd.apache.org/userslist.html> for more info.
To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
   "   from the digest: users-digest-unsubscribe@httpd.apache.org
For additional commands, e-mail: users-help@httpd.apache.org