twimg_redirect_orig

Redirect twimg to :orig

当前为 2014-09-08 提交的版本,查看 最新版本

  1. // ==UserScript==
  2. // @name twimg_redirect_orig
  3. // @namespace http://catherine.v0cyc1pp.com/twimg_redirect_orig.user.js
  4. // @include *://pbs.twimg.com/media/*
  5. // @include *://pbs.twimg.com/media/*:large
  6. // @exclude http://pbs.twimg.com/media/*:orig*
  7. // @author greg10
  8. // @license GPL 3.0
  9. // @version 1.0
  10. // @grant none
  11. // @description Redirect twimg to :orig
  12. // ==/UserScript==
  13.  
  14. var str = content.document.location + "";
  15.  
  16.  
  17. str = str.replace( /:(large|orig).*$/, "");
  18. str = str.replace( /^https:/, "http:");
  19. var ext = str.substr( str.length - 3, 3);
  20. console.log("ext="+ext);
  21.  
  22. var url = str + ":orig?." + ext;
  23.  
  24. window.location.replace( url );

QingJ © 2025

镜像随时可能失效,请加Q群300939539或关注我们的公众号极客氢云获取最新地址