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

爬取 leetcode 题目疑问

  •  
  •   hytirrb · May 27, 2024 · 2193 views
    This topic created in 896 days ago, the information mentioned may be changed or developed.

    各位佬,我要爬取下面这个页面的超链接以及里面的文本: https://leetcode.cn/circle/discuss/mOr1u6/,但是在开发者工具的 network 中的第一个请求的 response 的源代码没看到网页中超链接以及对应的文本内容,请问我该如何找到这些超链接的具体位置呢

    3 replies  •  2024-05-27 16:57:48 +08:00
    1018ji
    1018ji
    May 27, 2024
    1
    graphql 接口找找
    Aoyu
    Aoyu
    May 27, 2024
    2
    用无头浏览器 selenium 配合 xpath 最为便捷。
    yjfkk
    yjfkk
    May 27, 2024
    3
    graphql 需要 token ,单独发请求也无效,用浏览器渲染页面,获取 html 再解析
    About   ·   Help   ·   Advertise   ·   Blog   ·   API   ·   FAQ   ·   Privacy   ·   Solana   ·   921 Online   Highest 6679   ·     Select Language
    创意工作者们的社区
    World is powered by solitude
    VERSION: 3.9.8.5 · 33ms · UTC 20:49 · PVG 04:49 · LAX 12:49 · JFK 15:49
    ♥ Do have faith in what you're doing.