Clean Up Google!

Removes doodles, ads, and many other annoyances on the Google main page

您需要先安装一个扩展,例如 篡改猴Greasemonkey暴力猴,之后才能安装此脚本。

您需要先安装一个扩展,例如 篡改猴暴力猴,之后才能安装此脚本。

您需要先安装一个扩展,例如 篡改猴暴力猴,之后才能安装此脚本。

您需要先安装一个扩展,例如 篡改猴Userscripts ,之后才能安装此脚本。

您需要先安装一款用户脚本管理器扩展,例如 Tampermonkey,才能安装此脚本。

您需要先安装用户脚本管理器扩展后才能安装此脚本。

(我已经安装了用户脚本管理器,让我安装!)

您需要先安装一款用户样式管理器扩展,比如 Stylus,才能安装此样式。

您需要先安装一款用户样式管理器扩展,比如 Stylus,才能安装此样式。

您需要先安装一款用户样式管理器扩展,比如 Stylus,才能安装此样式。

您需要先安装一款用户样式管理器扩展后才能安装此样式。

您需要先安装一款用户样式管理器扩展后才能安装此样式。

您需要先安装一款用户样式管理器扩展后才能安装此样式。

(我已经安装了用户样式管理器,让我安装!)

// ==UserScript==
// @name        Clean Up Google!
// @namespace   ic55-userscript-normalgoogle
// @description Removes doodles, ads, and many other annoyances on the Google main page
// @include     *www.google.*
// @version     1.01
// @grant       none
// ==/UserScript==

//define elements to be removed
var gLogo = document.getElementById('hplogo'); //any logo + share buttons
var chromeAd = document.getElementById('prt'); //advertisment for Google Chrome
var textAd = document.getElementById('prm-pt'); //text below search bar
//define required elements for logo change
var newLogo = document.createElement('img');
var logoSpace = document.getElementById('lga');

//remove elements
chromeAd.parentNode.removeChild(chromeAd);
textAd.parentNode.removeChild(textAd);
gLogo.parentNode.removeChild(gLogo);

//insert new logo
newLogo.id = 'hplogo'; //must be hplogo to hide on auto search
newLogo.src = 'http://www.google.com/images/srpr/logo9w.png';
newLogo.style = 'padding-top: 110px; height: 95px; width: 269px;';
logoSpace.insertBefore(newLogo, logoSpace.childNodes[0]);