Tables with solid black borders?

Discussion in 'HTML' started by Michael Wilcox, Jul 7, 2003.

  1. If I do <table border=1> I get the standard outset border frames. How do I
    turn these into a solid, 1 pixel border (probably with css)? "border: 1px
    solid black" doesn't seem to do it right, so how do I do it?
    --
    Michael Wilcox
    Essential Tools for the Web Developer - http://mikewilcox.t35.com
    mjwilco at yahoo dot com
     
    Michael Wilcox, Jul 7, 2003
    #1
    1. Advertising

  2. In article <oC2Oa.85111$>,
    Michael Wilcox wrote:
    > If I do <table border=1> I get the standard outset border frames. How do I
    > turn these into a solid, 1 pixel border (probably with css)? "border: 1px
    > solid black" doesn't seem to do it right, so how do I do it?


    URL?

    table {border: 1px solid black}

    /* or depending on what you are after */

    table, td {border: 1px solid black;border-collapse:collapse;}

    <table><tr><td>Stuff</table>

    Most¹ browsers have bug that makes it look odd when border=1 is set in
    HTML.

    That is unfortunate, as it will degrade badly. If so happens, you can use
    HTML to set that, I don't remember how and it is deprecated and don't
    have full support either.

    [1] when I last checked, can't remember when.

    --
    Lauri Raittila <http://www.iki.fi/lr> <http://www.iki.fi/zwak/fonts>
    Saapi lähettää meiliä, jos aihe ei liity ryhmään, tai on yksityinen
    tjsp., mutta älä lähetä samaa viestiä meilitse ja ryhmään.
     
    Lauri Raittila, Jul 7, 2003
    #2
    1. Advertising

  3. Michael Wilcox

    Sid Ismail Guest

    On Sun, 06 Jul 2003 23:51:48 GMT, "Michael Wilcox"
    <> wrote:

    : If I do <table border=1> I get the standard outset border frames. How do I
    : turn these into a solid, 1 pixel border (probably with css)? "border: 1px
    : solid black" doesn't seem to do it right, so how do I do it?


    why not?
    <table style="border:2px solid black;"> does it fine.

    url? Wanna see if TDs require it.

    Sid
     
    Sid Ismail, Jul 7, 2003
    #3
  4. Lauri Raittila <> wrote:
    > In article <oC2Oa.85111$>,
    > Michael Wilcox wrote:
    >> If I do <table border=1> I get the standard outset border frames.
    >> How do I turn these into a solid, 1 pixel border (probably with
    >> css)? "border: 1px solid black" doesn't seem to do it right, so how
    >> do I do it?

    >
    > URL?
    >
    > table {border: 1px solid black}
    >
    > /* or depending on what you are after */
    >
    > table, td {border: 1px solid black;border-collapse:collapse;}


    Beautiful, thank you. I guess the collapse thing was exactly what I needed.
    --
    Michael Wilcox
    Essential Tools for the Web Developer - http://mikewilcox.t35.com
    mjwilco at yahoo dot com
     
    Michael Wilcox, Jul 7, 2003
    #4
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Mark Rae

    <asp:Panels, borders and HTML tables

    Mark Rae, Oct 6, 2004, in forum: ASP .Net
    Replies:
    3
    Views:
    5,036
    Mark Rae
    Oct 6, 2004
  2. Hostile17

    Borders For Tables Hack

    Hostile17, Sep 2, 2003, in forum: HTML
    Replies:
    2
    Views:
    523
    Philipp Lenssen
    Sep 2, 2003
  3. George
    Replies:
    9
    Views:
    4,919
    George
    Oct 25, 2004
  4. Jon

    Tables and borders

    Jon, May 17, 2005, in forum: HTML
    Replies:
    6
    Views:
    511
    Safalra
    May 20, 2005
  5. Helen

    Borders around tables?

    Helen, Feb 28, 2006, in forum: HTML
    Replies:
    3
    Views:
    571
    Jonathan N. Little
    Feb 28, 2006
Loading...

Share This Page