Fiddler:是否可以在不影响内容的情况下替换/隐藏部分URL?


0

我正在使用Fiddler调试代理,并且下面的代码可以拦截服务器(YouTube)数据并在HTML信息到达客户端之前修改它(我的web broswer)。

if (oSession.HostnameIs("www.youtube.com") && oSession.oResponse.headers.ExistsAndContains("Content-Type","text/html")){

            oSession.utilDecodeResponse();
            oSession.utilReplaceInResponse("old string","new string");
        }

现在,我想替换/隐藏这个词 dolphin http://www.youtube.com/results?search_query= dolphin &安培;页= 3。我怎样才能做到这一点?

谢谢

Answers:


1

if(oSession.url.Contains(“search_query = dolphin”)) {             oSession.url = oSession.url.Replace(“search_query = dolphin”,“search_query =”); }


1
您能否提供一些解释,而不仅仅是发布命令行?
Ob1lan
By using our site, you acknowledge that you have read and understand our Cookie Policy and Privacy Policy.
Licensed under cc by-sa 3.0 with attribution required.