Community Central

Changing the color of the backgrounds in Wikitable

  • Hello. I'm a Rollback user on the Grand Theft Auto Wiki. I was wondering if you could help with something:

    As you can see in the photo, our wiki has a black/greyish theme. That white background look very odd. Is there any way to change it forever? (MediaWiki or something) Or at least, something I can do for that particular Wikitable.

    Here's the link:

    Thank you!

      Loading editor
    • Hi, you can change the default color of a wikitable by using the following CSS:

      table.wikitable {
      	background-color: #696969;

      This code will need to be placed in w:c:gta:MediaWiki:Wikia.css. If you cannot edit MediaWiki: pages, you may need to ask an admin to edit it for you.

      See Help:Color for a list of colors. I chose a dim gray color (#696969 in the code above), but if you want a different color, it's easy to change.

      Edit: Your MediaWiki:Wikia.css page on your wiki already has code to set the background of wikitables in the following block of code:

      table.prettytable {
        margin: 1em 1em 1em 0;
        background: #f9f9f9;
        border: 1px #aaa solid;
        border-collapse: collapse;

      So in your case you would just need to change the color itself from #f9f9f9 to whatever you want to change it to.

        Loading editor
    • I know how to do it and also get color codes, but I'll have to ask an Admin since the page is protected. Thank you! :)

        Loading editor
    • I see. That's why it didn't worked. Thanks again.

        Loading editor
        Loading editor
Give Kudos to this message
You've given this message Kudos!
See who gave Kudos to this message

Ad blocker interference detected!

Wikia is a free-to-use site that makes money from advertising. We have a modified experience for viewers using ad blockers

Wikia is not accessible if you’ve made further modifications. Remove the custom ad blocker rule(s) and the page will load as expected.