Forum Discussion
dubdub
Oct 26, 2011Nimbostratus
HTTP::payload replace length
Hi all,
I used Colin's excellent example of replacing outbound payload content at http://devcentral.f5.com/Tutorials/...Rules.aspx - but was curious, that last line where it says:
HTTP::payloa...
dubdub
Oct 27, 2011Nimbostratus
Hi Michael,
I apologize, I really am not trying to be obtuse, I'm just confused :( Checking the link you sent - it says:
----
HTTP::payload replace offset length string
Replaces the amount of content that you specified with the length argument, starting at offset with string, adjusting the Content-Length header appropriately.
To clarify, the length argument should be the length of original content to replace. In order to replace the entire payload, the offset should be 0 and the length should be the original size in bytes of the payload. The original content length can typically be retrieved using [HTTP::header value Content-Length].
----
If I am trying to replace the entire original payload, don't I need to send the length of the original payload to the replace command, not the length of the new payload? I'm not following :(
Thanks,
Jen
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