Forum Discussion
keefyweefy
Mar 24, 2011Nimbostratus
simple stream replace not working
Hi Guys,
I'm trying to replace text within webpages but things
arn't going to plan! As a result i've stripped this to be as simple as
possible but still no joy. I've tried doing this two w...
keefyweefy
Mar 25, 2011Nimbostratus
Thank you both for your responses. It appears the text wasn't being replaced due to compression. I changed the irule to include:
when HTTP_REQUEST {
Disable the stream filter for all requests
STREAM::disable
remove the compression offerings from the client
HTTP::header remove "Accept-Encoding"
}
when HTTP_RESPONSE {
Check if response type is text
if {[HTTP::header value Content-Type] contains "text"}{
Replace
STREAM::expression {@Hello@12345@}
Enable the stream filter for this response only
STREAM::enable
}
}
I think the 'overload' function referred to by Michael will come in usefull when we go live.
Recent Discussions
Related Content
DevCentral Quicklinks
* Getting Started on DevCentral
* Community Guidelines
* Community Terms of Use / EULA
* Community Ranking Explained
* Community Resources
* Contact the DevCentral Team
* Update MFA on account.f5.com
Discover DevCentral Connects