• There is an important update regarding account security and 2FA. Please click here for more information.
  • Welcome to PokéCommunity! Register now and join one of the best fan communities on the 'net to talk Pokémon and more! We are not affiliated with The Pokémon Company or Nintendo.
  • Imgur has blocked certain regions from viewing any images uploaded to their site. If you use Imgur, please consider replacing any image links/embeds you may have on PokéCommunity so everyone can see your images. Click here to learn more.

CSS Question

PichuSecretBase

Web Site Critique
  • 2,775
    Posts
    22
    Years
    Okay Lets say I have a table and it is

    Code:
    <table class="contenttb"><td><td>Content!</td><td>MORE CONTENT!</td></tr></table>
    and this in my CSS
    Code:
    .contenttb {
    font-family: Verdana;
    font-size: 10px;
    color: #000000;
    border:solid 1px #000000; }
    Why does my table border only go around the edge and not between colomns and rows?
     
    @_@ I just tested it out and this seems to work:

    Code:
    <table class="newtableclass"><td><td class="contenttb">Content!</td><td class="contenttb">MORE CONTENT!</td></tr></table>
    Code:
    .newtableclass { 
     	border-collapse: collapse; 
       }
      .contenttb {
       	font-family: Verdana;
       	font-size: 10px;
       	color: #000000;
       	border-width: 1px;
       	border-style: solid;
       	border-color: #000000;
       }

    ^_^; The TD tags need to have their borders set individually. The "border-collapse" attribute basically gets rid of the cellspacing in-between.
     
    Change this:

    Code:
    <table class="contenttb"><td><td>Content!</td><td>MORE CONTENT!</td></tr></table>

    to this:

    Code:
    <table class="contenttb"><tr><td>Content!</td><td>MORE CONTENT!</td></tr></table>

    too.
     
    Back
    Top