Hide HF logo

Hides the hackforums logo

您需要先安裝使用者腳本管理器擴展,如 TampermonkeyGreasemonkeyViolentmonkey 之後才能安裝該腳本。

您需要先安裝使用者腳本管理器擴充功能,如 TampermonkeyViolentmonkey 後才能安裝該腳本。

您需要先安裝使用者腳本管理器擴充功能,如 TampermonkeyViolentmonkey 後才能安裝該腳本。

您需要先安裝使用者腳本管理器擴充功能,如 TampermonkeyUserscripts 後才能安裝該腳本。

你需要先安裝一款使用者腳本管理器擴展,比如 Tampermonkey,才能安裝此腳本

您需要先安裝使用者腳本管理器擴充功能後才能安裝該腳本。

(我已經安裝了使用者腳本管理器,讓我安裝!)

你需要先安裝一款使用者樣式管理器擴展,比如 Stylus,才能安裝此樣式

你需要先安裝一款使用者樣式管理器擴展,比如 Stylus,才能安裝此樣式

你需要先安裝一款使用者樣式管理器擴展,比如 Stylus,才能安裝此樣式

你需要先安裝一款使用者樣式管理器擴展後才能安裝此樣式

你需要先安裝一款使用者樣式管理器擴展後才能安裝此樣式

你需要先安裝一款使用者樣式管理器擴展後才能安裝此樣式

(我已經安裝了使用者樣式管理器,讓我安裝!)

// ==UserScript==
// @name         Hide HF logo
// @description  Hides the hackforums logo
// @namespace    hf_hide_logo
// @version      0.1
// @author       Remix
// @require      https://code.jquery.com/jquery-2.1.4.min.js
// @include      http://*.hackforums.net/*
// @include      http://hackforums.net/*
// @grant        GM_getValue
// @grant        GM_setValue
// ==/UserScript==

hide = GM_getValue('hide', false);

if (hide) {
    $("img[src='http://hackforums.net/images/modern_bl/logo_bl.gif']").hide();
}

if (location.href.match(/usercp.php/i)) {
    $('select[name="daysprune"]').after('<br><input type="checkbox" id="hide_logo" name="hide_logo"><span class="smalltext"><label for="hide_logo">Hide logo</label></span>');
    
    var element = $('input[name="hide_logo"]');
    element.css('font-size', '9pt');
    element.css('margin-top', '10px');
    element.attr('checked', hide);

    $('input[name="regsubmit"]').on('click', function() {
        GM_setValue('hide', $('input[name="hide_logo"]').prop('checked'));
    });
}