Skip to content

如何利用抓包内容,编写GET中headers配置信息? #8366

Answered by auto-bot-ty
Derekmini asked this question in Q&A
Discussion options

You must be logged in to vote
const $ = cheerio.load(response.body);
const out = $(".title_item")
  .map((i, e) => {
    $(e).find(".access-text").remove();
    return {
      title: $(e).find(".hlFld-Title").text(),
      link: $(e).find(".ref.nowrap").attr("href"),
      pubDate: $(e).find(".open-access.item-access").text(),
    };
  })
  .get();
console.log(out);

Replies: 3 comments 7 replies

Comment options

You must be logged in to vote
7 replies
@Derekmini
Comment options

@auto-bot-ty
Comment options

@Derekmini
Comment options

@auto-bot-ty
Comment options

@Derekmini
Comment options

Answer selected by Derekmini
Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
0 replies
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants