Default Table Settings

Teleute
Teleute
edited November 2013 in Campaign Portal Building
I've finally gotten most of my pages under control but one thing has still been bugging me. Before the Reforge, my tables had transparent backgrounds. Now they all seem to default to alternating rows of white and grey. Has anyone created some CSS to changes this back to transparent across a whole campaign? Alternatively, would someone be willing to assist me?

Comments

  • madartiste
    madartiste
    Posts: 328
    Courtesy of Basileus:
    @/* RESTORES PREFORGE TABLE FUNCTIONALITY */
    #content table {background-color: transparent; border-style: none;}
    #content tr:nth-child(even) {background-color: transparent;}@
  • Teleute
    Teleute
    Posts: 9
    Thank you! With that I am pretty much done with all my changes!
  • twiggyleaf
    twiggyleaf
    Posts: 2,011
    Hey madartiste,My tables had alternating lines of white and grey anyway, but they were solid across the horizontal. Now they show the blocks they are made of with vertical stripes. Do you have a FIX idea for that?

    "I met a traveller from an antique land....."

    CotM May 2016: Mysteria: set in Wolfgang Baur’s MIDGARD.

    Previous CotM Aug 2012: Shimring: High Level Multiplanar Campaign

    Inner Council Member

  • madartiste
    madartiste
    Posts: 328 edited November 2013
    Twiggy, any chance you could link me an example? It might just be the default border causing trouble.
    Maybe @#content table {border-collapse:collapse;}@ would fix it, but I'd have to see what you mean first.
    Post edited by madartiste on
  • twiggyleaf
    twiggyleaf
    Posts: 2,011
    Actually, Madartise, that has fixed it, but it seems to have cut off a bit of the black borderline on the right hand side.

    Have a look "here:":https://mysteria.obsidianportal.com/wikis/house-rules

    twigs

    "I met a traveller from an antique land....."

    CotM May 2016: Mysteria: set in Wolfgang Baur’s MIDGARD.

    Previous CotM Aug 2012: Shimring: High Level Multiplanar Campaign

    Inner Council Member

  • madartiste
    madartiste
    Posts: 328 edited November 2013
    Huh. It might be because those last TDs in your tables are empty...
    Could you try: @#content table tr td:last-child {border-right:1px solid black;}@
    Post edited by madartiste on
  • twiggyleaf
    twiggyleaf
    Posts: 2,011
    Hey Mad

    Thanks very much. That does the trick, alright!
    You CSS guys are TRUE WIZARDS!

    twigs

    "I met a traveller from an antique land....."

    CotM May 2016: Mysteria: set in Wolfgang Baur’s MIDGARD.

    Previous CotM Aug 2012: Shimring: High Level Multiplanar Campaign

    Inner Council Member

  • PhoenixMark
    PhoenixMark
    Posts: 90 edited November 2013
    I put that code in my CSS box but still have issues. Any help? It used to be yellow text against the maroon jpg background.

    "Example Here":https://crimson-skies.obsidianportal.com/wikis/recent-additions

    Thanks,

    "PhoenixMark":http://www.obsidianportal.com/profile/PhoenixMark

    "CRIMSON SKIES":http://www.obsidianportal.com/campaigns/crimson-skies
    "COTM June 2012":http://blog.obsidianportal.com/crimson-skies-junes-campaign-of-the-month/

    Also "Sactown Blues":http://www.obsidianportal.com/campaigns/sactown-blues and "Shimmering Kingdoms":http://www.obsidianportal.com/campaigns/shimmering-kingdoms
    Post edited by PhoenixMark on
  • GamingMegaverse
    GamingMegaverse
    Posts: 3,001
    This is the whole of my table css
    /*TABLE CODE*/

    table {background-color: transparent;
    border:inherit;}

    #content table {background-color: transparent; border-style: none;}
    #content tr:nth-child(even) {background-color: transparent}

    table td {font-size:20px;}

    table {margin:0px auto;}

    #content table {border-collapse:collapse;}

    Try that PhoenixMark
    killervp
    "A God...Rebuilt":https://a-god-rebuilt.obsidianportal.com
    "OP's COTM April 2012":http://blog.obsidianportal.com/a-god-rebuilt-aprils-cotm/
    Here to help anyone- Send me a PM

    Just trying to help out.

  • PhoenixMark
    PhoenixMark
    Posts: 90
    Killervp,

    I added that, didn't change a thing. Must be crap in my HTML.
  • PhoenixMark
    PhoenixMark
    Posts: 90
    Not sure what I did, but the tables are ok now. Thanks.
  • SkidAce
    SkidAce
    Posts: 830
    If you set a default color, say "blue" in your css, THEN on a particular wiki page set the color to "green", which one takes precedence.
  • madartiste
    madartiste
    Posts: 328 edited November 2013
    Inline CSS usually takes precedence over CSS from an external stylesheet -- as far as I know. IE, stuff set on a specific page will take over for things put in your custom CSS page section.
    Post edited by madartiste on
  • Langy
    Langy
    Posts: 364
    More specific CSS takes precedence.

    Note that the !important tag takes precedence over anything without !important.
  • SkidAce
    SkidAce
    Posts: 830
    Thanks all, will be testing.
  • SkidAce
    SkidAce
    Posts: 830
    You folks are heroes, here is an example of what I used to have to try and ct and paste and fill in the right blocks;

    @
    The Pantheon

    Diety
    Alignment
    Favored Weapon
    Portfolio
    Devotees



    [[Rao]]
    Good
    Rod
    Wisdom, Serenity, Magic, Jinn
    Rulers, Teachers, Clerics, Wizards
    @

    Now I put the below code in my CSS, and all I have to do if I want a table is use the pipe character for the cells. So much happier.

    Thanks again and again.

    @/* TABLE STANDARDS */
    table {margin:0px auto;}
    #content table{background-color:#white; border-style:solid; border-color:#1e90ff;}
    #content tr:nth-of-type(1){background:#1e90ff;}
    #content tr:nth-child(even) {background-color:#ddd}
    #content table {border-collapse:collapse;}
    @
  • SkidAce
    SkidAce
    Posts: 830
    Heres an edited example, nothing but text, pipes, and brackets.

    "Old Faith":https://alfaysia.obsidianportal.com/wikis/old-faith
Sign In or Register to comment.

April 2024
Season of Strife

Read the feature post on the blog
Return to Obsidian Portal

Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

Discussions