Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8498351
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 11, 20262026-06-11T00:22:42+00:00 2026-06-11T00:22:42+00:00

Recently I decided to write a very simple Google Chrome extension. All it’s going

  • 0

Recently I decided to write a very simple Google Chrome extension. All it’s going to do is to hide some DOM-elements from the web-page using JavaScript when user presses the extension’s button.

Since I knew nothing about Chrome extensions, I started reading tutorials, and I came across this Google’s sample: A browser action with no icon that makes the page red

This sample is really close to what I want to make. The problem is that I can’t make it work. Whenever I load the extension in Chrome, I can see the button of this extension, but when I press it – nothing happens. Sample doesn’t work, probably I should know something I don’t know yet.

And before you started asking me:

  • Yes, I tried restarting the browser;
  • I use the newest version of Chrome.

Thanks for help.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-11T00:22:44+00:00Added an answer on June 11, 2026 at 12:22 am

    If you open up the sample zip… find backgrond.js… edit.
    Find the line that says:

    null, {code:"document.body.style.background='red !important'"});
    

    and remove the “!important”. so it should read:

    null, {code:"document.body.style.background='red'"});
    

    That is it. just save and reload the extension, should work (unless the page has an !important flag set to the background).

    I am afraid I don’t know why the “!important” tag doesn’t work but I have never been able to get it to work in an extension. Hopefully someone else here will be able to give an explanation and maybe a work around.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I've been working with some event handling in Javascript and recently decided to migrate
I have been studying python for quite sometime now and very recently I decided
I have recently decided to switch all my current plain mysql queries performed with
I have a simple SQLite database I use to track invoices. I recently decided
I recently decided to try to learn some bash scripting and as a fun
I recently decided to try some java web development, so I installed xampp, the
Recently I tried to write a simple compiler on the linux platform by myself.
I've recently decided to start using some light unit testing to see if it
Recently decided to write a quick windows form app to tag my MP3 files.
I've recently decided to write a launcher for my project. It simply downloads updated

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.