Modify HTML Content with Squid
Posted
by user38400
on Server Fault
See other posts from Server Fault
or by user38400
Published on 2010-03-24T07:30:03Z
Indexed on
2010/03/24
7:33 UTC
Read the original article
Hit count: 339
We have setup our network as per the tutorial here: https://help.ubuntu.com/community/Upside-Down-TernetHowTo. Basically, we have a squid proxy that inverts images for pages that clients request.
We're trying to modify the script so that we can edit the contents of the webpage before the webpage is sent to the client. We are not having any luck. I'm wondering if there is something different about .html files that makes this not possible.
What is happening is that we do a wget on the URI that is requested, save it locally, modify it and then echo back the new URI. The page that the user gets is the unmodified page and not the one that we just changed.
© Server Fault or respective owner