Greasy Fork 支持简体中文。

重定向B站视频分享链接

将B站链接重定向到单独的视频页面

  1. // ==UserScript==
  2. // @name 重定向B站视频分享链接
  3. // @namespace https://greasyfork.org/zh-CN/scripts/479942
  4. // @version 0.1.4
  5. // @description 将B站链接重定向到单独的视频页面
  6. // @author rteta
  7. // @match https://www.bilibili.com/*bvid=*
  8. // @exclude https://www.bilibili.com/festival/*
  9. // @exclude https://www.bilibili.com/video/*/?bvid=*
  10. // @grant none
  11. // @license MIT
  12. // ==/UserScript==
  13.  
  14. (function() {
  15. 'use strict';
  16. var url = window.location.href;
  17. var cleanUrl = url.split('&')[0];
  18. window.location.href = cleanUrl.replace("/?bvid=", "/video/") + "/?t=0";
  19. })();
  20.  
  21. //将域名里的 /?bvid= 替换为 /video/ 并且在末尾加上 /?t=0