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

  • Home
  • SEARCH
  • 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 107819
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 11, 20262026-05-11T01:48:50+00:00 2026-05-11T01:48:50+00:00

Title pretty much sums it up. The external style sheet has the following code:

  • 0

Title pretty much sums it up.

The external style sheet has the following code:

td.EvenRow a {   display: none !important; } 

I have tried using:

element.style.display = 'inline'; 

and

element.style.display = 'inline !important'; 

but neither works. Is it possible to override an !important style using javascript.

This is for a greasemonkey extension, if that makes a difference.

  • 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. 2026-05-11T01:48:51+00:00Added an answer on May 11, 2026 at 1:48 am

    I believe the only way to do this it to add the style as a new CSS declaration with the ‘!important’ suffix. The easiest way to do this is to append a new <style> element to the head of document:

    function addNewStyle(newStyle) {     var styleElement = document.getElementById('styles_js');     if (!styleElement) {         styleElement = document.createElement('style');         styleElement.type = 'text/css';         styleElement.id = 'styles_js';         document.getElementsByTagName('head')[0].appendChild(styleElement);     }     styleElement.appendChild(document.createTextNode(newStyle)); }  addNewStyle('td.EvenRow a {display:inline !important;}') 

    The rules added with the above method will (if you use the !important suffix) override other previously set styling. If you’re not using the suffix then make sure to take concepts like ‘specificity‘ into account.

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

Sidebar

Related Questions

Pretty much what the title says really. We have some code that is .NET
Title pretty much sums it up. I just found out about this function and
The title pretty much sums it up. I would use VS2010 for SilverLight, WPF,
The question title pretty much sums it up... I haven't been able to find
I think the title of my question pretty much sums it all up. I'm
title pretty much says it all. I have a website which will only run
Title pretty much says it all. I have a page called login.jsp: <f:view> <html>
The title pretty much says it all. A cookie seems to have a few
My title pretty much says it all. I have been looking at mod_pagespeed and
The title pretty much says it all. Some caveats are: I need to be

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.