Hello and welcome to our community! Is this your first visit?
Register
Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 5 of 5
  1. #1
    New Coder
    Join Date
    Jun 2003
    Posts
    29
    Thanks
    3
    Thanked 0 Times in 0 Posts

    Question In CSS, can you specify cell borders ??

    In CSS, you can specify an id selector that specifies table borders when the id is used:

    #para {
    position:relative;
    border-collapse:collapse;
    border-style:ridge;
    border-color:"#0000ff";
    }

    My question: In an id selector, can you specify the borders of individual table cells?

    I know you can go in to the HTML for each table, and specify borders for each cell individually.

    Thanks, Wayne

    PS This is related to my earlier quesiton, Table border question.

  • #2
    Senior Coder effpeetee's Avatar
    Join Date
    Feb 2007
    Location
    Clapham Junction - London SW
    Posts
    4,885
    Thanks
    228
    Thanked 204 Times in 203 Posts
    Is this any help to you.

    Tables I hardly ever use. This is the best I can do.

    Frank
    * Sources (updated: 21.11.2012.
    Using Windows 8 Professional. 64bit with HP Photosmart 5510 printer Very useful site here.

  • #3
    Senior Coder
    Join Date
    Aug 2010
    Location
    High Point, NC
    Posts
    3,332
    Thanks
    5
    Thanked 363 Times in 360 Posts
    Then I'll post the same response I did in your other thread.

    I have to ask why are you using tables at all? Read about why tables for layouts are bad here.
    Teed

  • #4
    Senior Coder DanInMa's Avatar
    Join Date
    Nov 2010
    Location
    Salem,Ma
    Posts
    1,577
    Thanks
    13
    Thanked 248 Times in 248 Posts
    short answer, yes, but it can be a pain and some browsers don't like it very much.

    The fact that your also using postion:relative makes me wonder if what you are doing is a bad idea in the first place, though. You might want to look at the link Teedoff provided.

    a more informative article can be found here - http://webdesign.about.com/od/layout/a/aa111102a.htm

  • #5
    New Coder
    Join Date
    Jun 2003
    Posts
    29
    Thanks
    3
    Thanked 0 Times in 0 Posts
    OK from reading one of the links posted, I now see that I can code:

    #para td { ...

    The td is new. That makes it apply to the cells, instead of the whole table.

    Thanks, all


  •  

    Tags for this Thread

    Posting Permissions

    • You may not post new threads
    • You may not post replies
    • You may not post attachments
    • You may not edit your posts
    •