This forum has been moved here:
Helicon Tech Community Forum

Helicon Ape (Forum Locked Forum Locked)
 Helicon Tech : Helicon Ape
Subject Topic: ReplaceFilterDefine multiple mimetypes
Author
Message |
mhaslhofer
Newbie


Joined: 05 January 2012
Posts: 2
Posted: 05 January 2012 at 9:40am

Hi,

i need to use mod_replace for multiple mimetypes (text/html,text/css,text/xml) to reverseproxy an Ajax application.

the "intype" parameter in mod_replace does only take one mimetype. I tried using "text" or "text/*" or "text/.*" to match all text-types - but that didn't work.

I can't define multiple ReplaceFilters (for different mime-types) - the last ReplaceFilter, set via "SetEnv modreplace=<filtername>" overrules the other filters.

I tried to use "SetEnvIfNoCase Mime ^text/xml modreplace=xmlfilter" but that didn't work either (i guess that modreplace is executed, before Mime - Header is available)

Is there another way to solve this, other than using Request_URI - matching in combination with "SetEnvIf" ?

cheers,

moritz

Back to Top
 
Guests
Guest


Joined: 01 October 2003
Online Status: Online
Posts: -160
Posted: 06 January 2012 at 7:11am

try using smth like:

Code:
ReplaceFilterDefine revproxy CaseIgnore intype=text/
ReplacePattern revproxy "(http|https)://origin.server/" "\1://revproxy/"
SetEnv mod_replace revproxy


Regards
Andrew
Back to Top
 
mhaslhofer
Newbie


Joined: 05 January 2012
Posts: 2
Posted: 09 January 2012 at 8:02am

Hi Andrew,

"text/" did work

thank you very much!

cheers,

moritz

Back to Top
 

Sorry, you can NOT post a reply.
This forum has been locked by a forum administrator.

Printable version Printable version