gpt4 book ai didi

ruby - 如何使用 Ruby Mechanize 自动为 Facebook 帖子点赞

转载 作者:太空宇宙 更新时间:2023-11-03 17:06:02 26 4
gpt4 key购买 nike

我正在尝试创建一个自动“喜欢”Facebook 帖子的机器人。使用 Mechanize 我可以登录 facebook,但不幸的是,Mechanize 无法理解指向“赞”按钮的链接——它们似乎被 JS 混淆了。我看到的唯一链接是基础知识,例如:

 <Mechanize::Page::Link
"Edit friends"
"http://www.facebook.com/friends/?ref=tn">
<Mechanize::Page::Link "Developers" "http://developers.facebook.com/?ref=pf">
<Mechanize::Page::Link "Careers" "/careers/?ref=pf">
<Mechanize::Page::Link "Terms" "/terms.php?ref=pf">
<Mechanize::Page::Link "Find friends" "/find-friends/?ref=pf">
<Mechanize::Page::Link "Privacy" "/policy.php?ref=pf">
<Mechanize::Page::Link "Mobile" "/mobile?ref=pf">
<Mechanize::Page::Link "Help Centre" "/help/?ref=pf">

有谁知道我怎样才能让 Mechanize 看到“赞”链接?

谢谢

最佳答案

为什么不尝试点击该网站的移动版本。 http://m.facebook.com .看起来 Like 链接没有使用任何 JS。

关于ruby - 如何使用 Ruby Mechanize 自动为 Facebook 帖子点赞,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/2379618/

26 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com