TextFugu Link Fix

Gets rid of the #top at the end of links on all the lessons pages

当前为 2015-05-31 提交的版本,查看 最新版本

  1. // ==UserScript==
  2. // @name TextFugu Link Fix
  3. // @namespace thenn42.eu/userscripts
  4. // @description Gets rid of the #top at the end of links on all the lessons pages
  5. // @include *www.textfugu.com/*
  6. // @version 1.3
  7. // @grant none
  8. // @require https://ajax.googleapis.com/ajax/libs/jquery/2.1.3/jquery.min.js
  9. // ==/UserScript==
  10.  
  11. $('p').html(function (i, text) {
  12. return text.replace(
  13. /(href[-\.="/\w]+?)#top/gi,
  14. '$1');
  15. });