【问题标题】:Twitter Web Intents: Retweet link does not appearTwitter Web Intents:转推链接不出现
【发布时间】:2018-12-17 03:01:18
【问题描述】:

我想使用 Twitter Web Intents 来显示“点赞”和“转推”操作的模式窗口。我的代码(根据https://developer.twitter.com/en/docs/twitter-for-websites/web-intents/overview

<html>
    <header>
        <title>Twitter</title> 
    </header>
    <body>
        <a href="https://twitter.com/intent/retweet?tweet_id=463440424141459456">Retweet</a>
        <a href="https://twitter.com/intent/like?tweet_id=463440424141459456">Like</a>

        <script type="text/javascript" async src="https://platform.twitter.com/widgets.js"></script>
    </body>
</html>

但我看到的只是“喜欢”链接。没有出现“转推”链接。

Chrome DevTools Screenshot

我做错了什么?

【问题讨论】:

    标签: html web twitter


    【解决方案1】:

    好的,我的回答是:原因是浏览器的“AdGuard”扩展。它添加了“注入样式表”。规则之一:

    a[href^="https://twitter.com/intent/retweet?tweet_id"]{
        display: none !important;
    } 
    

    Chrome DevTools Screenshot

    对不起,这是我的疏忽。

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 2014-03-10
      • 2018-11-18
      • 1970-01-01
      • 1970-01-01
      • 2011-08-04
      • 2016-03-16
      相关资源
      最近更新 更多