Who the Fuck uses GOOGLE+?

A script which removes the google plus +1 sign

目前為 2016-05-11 提交的版本,檢視 最新版本

// ==UserScript==
// @name        Who the Fuck uses GOOGLE+?
// @namespace   MegaByteWTFUG
// @description A script which removes the google plus +1 sign
// @require     http://ajax.googleapis.com/ajax/libs/jquery/1.9.1/jquery.min.js
// @run-at      document-idle
// @include     *
// @version     0.1
// @grant       none
// ==/UserScript==


    if(!('contains' in String.prototype)) {
       		String.prototype.contains = function(str, startIndex) {
                	return -1 !== String.prototype.indexOf.call(this, str, startIndex);
       		};
 	}

    this.$ = this.jQuery = jQuery.noConflict(true);

    $("[class*=googleplus], [class*=google_plus], [class*=gplus], [class*=g_plus], [id*=googleplus], [id*=google_plus], [id*=gplus], [id*=g_plus]").remove();

    var site = window.location.href || document.URL;
    if(site.contains("plus.google.com")) {
        var content = $("body > *");
        content.remove();
        $("body").append("                                                      \
           <center style='margin-top: 25px;'>              \
              <h1 style='margin-bottom: 10px;'>Are you sure you want to be here?</h1>                        \
              <input type='button' value='Take me Away!' class='_away' />       \
              <input type='button' value='Show site!' class='_show' />          \
           </center>                                                            \
        ");
        $("._show").click(function() {
           $("body > *").remove();
            $("body").append(content);
        });
        $("._away").click(function() {
           window.location.href = document.referrer;
        });
    }

QingJ © 2025

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