1. Welcome to Tacoma World!

    You are currently viewing as a guest! To get full-access, you need to register for a FREE account.

    As a registered member, you’ll be able to:
    • Participate in all Tacoma discussion topics
    • Communicate privately with other Tacoma owners from around the world
    • Post your own photos in our Members Gallery
    • Access all special features of the site

Tacomaworld Tampermonkey

Discussion in 'Off-Topic Discussion' started by soggyBottom, Feb 24, 2024.

  1. Feb 24, 2024 at 11:40 AM
    #1
    soggyBottom

    soggyBottom [OP] Well-Known Member

    Joined:
    Sep 19, 2018
    Member:
    #266818
    Messages:
    1,937
    I made a Tampermonkey script to customize your main page the way you want it. It basically excludes specific threads on Tacomaworld. For example, if you don't live in NewEngland and don't want to see that thread, add the thread number to the array, refresh the page and it's gone!

    Code:
    // ==UserScript==
    // @name         New Userscript
    // @namespace    http://tampermonkey.net/
    // @version      2024-02-24
    // @description  try to take over the world!
    // @author       You
    // @match        https://www.tacomaworld.com/
    // @icon         https://www.google.com/s2/favicons?sz=64&domain=tacomaworld.com
    // @grant        none
    // ==/UserScript==
    (function() {
        'use strict';
        var threadNumbers = [
            '204874', // New England B.S. Thread,
            // Add more thread IDs here.
        ];
        var selectors = threadNumbers.map(function(number) {
            return 'li[id^="thread-' + number + '"]';
        });
        var selectorString = selectors.join(', ');
        var liElements = document.querySelectorAll(selectorString);
        // To remove the elements
        liElements.forEach(function(element) {
            element.remove();
        });
    })();
    
     
    Last edited: Feb 24, 2024
    rocknbil, Speedytech7 and 0xDEADBEEF like this.
  2. Feb 24, 2024 at 11:52 AM
    #2
    CraigF

    CraigF Well-Known Member

    Joined:
    Jun 21, 2020
    Member:
    #332105
    Messages:
    1,759
    Gender:
    Male
    First Name:
    Craig
    Oak Grove, OR
    Vehicle:
    06 AC PR OR 4.0L
    none yet
    will it work for "best oil" threads regardless of section?
     
    rocknbil likes this.
  3. Feb 24, 2024 at 12:08 PM
    #3
    jrallan26

    jrallan26 Well-Known Member

    Joined:
    Sep 10, 2006
    Member:
    #32
    Messages:
    1,263
    Gender:
    Male
    Iowa
    Vehicle:
    2004 White D-Cab TRD
    Will these tires fit?
     
    rocknbil likes this.
  4. Feb 24, 2024 at 12:10 PM
    #4
    Just_A_Guy

    Just_A_Guy Rain is a good thing

    Joined:
    Oct 4, 2021
    Member:
    #378864
    Messages:
    3,919
    On the hunt
    Vehicle:
    A truck
  5. Feb 24, 2024 at 12:11 PM
    #5
    0xDEADBEEF

    0xDEADBEEF Swaying to the Symphony of Destruction

    Joined:
    Mar 2, 2019
    Member:
    #285037
    Messages:
    19,644
    Vehicle:
    2000 reg cab 4x4 flatbed MT
    Can I hide the 3rd gen section?
     
    Speedytech7 and Just_A_Guy like this.
  6. Feb 24, 2024 at 12:12 PM
    #6
    Just_A_Guy

    Just_A_Guy Rain is a good thing

    Joined:
    Oct 4, 2021
    Member:
    #378864
    Messages:
    3,919
    On the hunt
    Vehicle:
    A truck
    FIFY
     
  7. Feb 24, 2024 at 12:13 PM
    #7
    soggyBottom

    soggyBottom [OP] Well-Known Member

    Joined:
    Sep 19, 2018
    Member:
    #266818
    Messages:
    1,937
    Am I not allowed to post this?
     
    Just_A_Guy[QUOTED] likes this.
  8. Feb 24, 2024 at 12:14 PM
    #8
    0xDEADBEEF

    0xDEADBEEF Swaying to the Symphony of Destruction

    Joined:
    Mar 2, 2019
    Member:
    #285037
    Messages:
    19,644
    Vehicle:
    2000 reg cab 4x4 flatbed MT
    Maybe anything >2
     
    Just_A_Guy[QUOTED] likes this.
  9. Feb 24, 2024 at 12:17 PM
    #9
    Just_A_Guy

    Just_A_Guy Rain is a good thing

    Joined:
    Oct 4, 2021
    Member:
    #378864
    Messages:
    3,919
    On the hunt
    Vehicle:
    A truck
    If I thought you couldn’t post this, I would have reported it

    I think it’s cool and Mr Bob might be interested as the creator/overlord of the site
     
  10. Mar 1, 2024 at 7:53 AM
    #10
    rocknbil

    rocknbil Well-Known Member

    Joined:
    Jan 5, 2023
    Member:
    #414860
    Messages:
    1,031
    Gender:
    Male
    First Name:
    Bill
    Vehicle:
    2003 Taco Ext Cab DLX TRD 4WD MT 3.4L
    Nice, clean use of objects and preg matches, compact, applies SRP, cranky lifetime coder approves! :-D (Not that it matters)
     
  11. Mar 1, 2024 at 10:59 AM
    #11
    Just_A_Guy

    Just_A_Guy Rain is a good thing

    Joined:
    Oct 4, 2021
    Member:
    #378864
    Messages:
    3,919
    On the hunt
    Vehicle:
    A truck
    Dm93 and 0xDEADBEEF like this.

Products Discussed in

To Top