yanwen
V2EX  ›  问与答

如何不安装网易新闻 app,查看网友分享出来的新闻评论

  •  
  •   yanwen · Mar 19, 2020 · 2218 views
    This topic created in 2291 days ago, the information mentioned may be changed or developed.

    网易新闻的一大亮点是他的评论,但是碍于网友分享出来都需要下载 app 才可以查看评论。对于不想下载 app 的人怎么查看评论呢?

    这里有一个方法。

    以下举个例子:

    新闻 app 的连接是这个

    https://c.m.163.com/news/a/F83IRJ3G0001899O.html?spss=newsapp
    

    点击查看评论,会提示你下载 app。好,现在我们把目光转移到 PC 端的新闻网页连接:

    https://news.163.com/20/0319/16/F83IRJ3G0001899O.html
    

    然后我们查看 PC 端的评论是这个:

    http://comment.tie.163.com/F83IRJ3G0001899O.html
    

    然后 F83IRJ3G0001899O.html 这个是一样的。

    所以,我们要查看评论的话,只需要把这串东西复制出来,拼接到网址 http://comment.tie.163.com/ 的后面就可以了。

    JS 不大熟悉。如果大佬有空的话 求帮忙写个 user.js 。

    金币感谢。

    3 replies    2020-03-20 00:35:16 +08:00
    Athrob
        1
    Athrob  
       Mar 20, 2020   ❤️ 1
    ```
    // ==UserScript==
    // @name 网易新闻跟贴
    // @namespace http://tampermonkey.net/
    // @version 0.1
    // @description try to take over the world!
    // @author You
    // @match https://c.m.163.com/news/a/*.html*
    // @grant none
    // @require https://cdn.jsdelivr.net/npm/[email protected]/dist/jquery.min.js
    // ==/UserScript==

    (function() {
    'use strict';

    var tie = $('.reply.js-reply.js-open-newsapp');
    var id = tie.attr('data-param');
    var url = 'https://comment.tie.163.com/' + id.replace('tie\/', '') + '.html';
    var html = '<span class="reply"><a href="' + url + '" target="_blank">😂查看跟贴</a></span>';
    tie.parent().append(html);
    })();
    ```
    Athrob
        2
    Athrob  
       Mar 20, 2020   ❤️ 1
    yanwen
        3
    yanwen  
    OP
       Mar 20, 2020
    @Athrob 谢谢大佬~~~
    About   ·   Help   ·   Advertise   ·   Blog   ·   API   ·   FAQ   ·   Solana   ·   3003 Online   Highest 6679   ·     Select Language
    创意工作者们的社区
    World is powered by solitude
    VERSION: 3.9.8.5 · 50ms · UTC 02:56 · PVG 10:56 · LAX 19:56 · JFK 22:56
    ♥ Do have faith in what you're doing.