• 请不要在回答技术问题时复制粘贴 AI 生成的内容
q1q1gg
V2EX  ›  程序员

有什么办法可以实现对网页下所有元素资源所在 ip 监控?

  •  
  •   q1q1gg · Aug 15, 2019 · 1323 views
    This topic created in 2499 days ago, the information mentioned may be changed or developed.

    想写个脚本监控某主页中所有元素的归属 ip 是否正确,用 selenium 试着搞了下没搞定。期望的最终效果类似 ChromeF12 下的 network,能拿到元素 url 及其对应的 ip 即可。

    DsuineGP
        1
    DsuineGP  
       Aug 15, 2019
    提供个思路,先拿到页面上资源的 url,用 XMLHttpRequest 请求资源,然后解响应头中的 Remote Address,应该很容易吧
    About   ·   Help   ·   Advertise   ·   Blog   ·   API   ·   FAQ   ·   Solana   ·   2411 Online   Highest 6679   ·     Select Language
    创意工作者们的社区
    World is powered by solitude
    VERSION: 3.9.8.5 · 27ms · UTC 15:42 · PVG 23:42 · LAX 08:42 · JFK 11:42
    ♥ Do have faith in what you're doing.