Results 1 to 9 of 9

Thread: Table borders

  1. #1
    Join Date
    Jul 2005
    Location
    cali
    Posts
    95
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default Table borders

    How would you change the color of a table border, to where it looks similar to this.



    but i want the border to blue.. it is blue in original context, and i want it to outline the outside of the table only, but i might use it to divide content later on so you can tell me how to do that too =).

    HTML. Thankz for your help.
    Last edited by bubba.daniel; 08-05-2005 at 02:53 PM.

  2. #2
    Join Date
    Jul 2005
    Location
    cali
    Posts
    95
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default

    I can deal with the border on the inside... all you have to do is make the border and make new rows, but i want to know how do you change it to blue.
    and, do i have to use a special tag?
    Last edited by bubba.daniel; 08-05-2005 at 02:59 PM.

  3. #3
    Join Date
    Jun 2005
    Location
    英国
    Posts
    11,876
    Thanks
    1
    Thanked 180 Times in 172 Posts
    Blog Entries
    2

    Default

    border-color: attribute. border-color-left, border-color-right, border-color-top, border-color-bottom.
    Twey | I understand English | 日本語が分かります | mi jimpe fi le jbobau | mi esperanton komprenas | je comprends français | entiendo español | tôi ít hiểu tiếng Việt | ich verstehe ein bisschen Deutsch | beware XHTML | common coding mistakes | tutorials | various stuff | argh PHP!

  4. #4
    Join Date
    Jul 2005
    Location
    cali
    Posts
    95
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default

    what is the exact tag?

  5. #5
    Join Date
    Jun 2005
    Location
    英国
    Posts
    11,876
    Thanks
    1
    Thanked 180 Times in 172 Posts
    Blog Entries
    2

    Default

    It's not a tag, it's CSS.
    Twey | I understand English | 日本語が分かります | mi jimpe fi le jbobau | mi esperanton komprenas | je comprends français | entiendo español | tôi ít hiểu tiếng Việt | ich verstehe ein bisschen Deutsch | beware XHTML | common coding mistakes | tutorials | various stuff | argh PHP!

  6. #6
    Join Date
    Jul 2005
    Location
    cali
    Posts
    95
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default

    tables arent css...

    and i found out the hard way, bordercolor="######" can do it
    but, how do i make the lines very thin like the table in the image

  7. #7
    Join Date
    Jun 2005
    Location
    英国
    Posts
    11,876
    Thanks
    1
    Thanked 180 Times in 172 Posts
    Blog Entries
    2

    Default

    You use CSS. This is the point of CSS. I know, funnily enough, that "tables arent css." However, it's perfectly possible to apply CSS to an HTML element (i.e. the table) to make it look different to the default. Try border-width: (border-top-width: border-bottom-width: border-left-width: border-right-width:).
    Twey | I understand English | 日本語が分かります | mi jimpe fi le jbobau | mi esperanton komprenas | je comprends français | entiendo español | tôi ít hiểu tiếng Việt | ich verstehe ein bisschen Deutsch | beware XHTML | common coding mistakes | tutorials | various stuff | argh PHP!

  8. #8
    Join Date
    Jul 2005
    Location
    cali
    Posts
    95
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default

    Quote Originally Posted by Twey
    Try border-width: (border-top-width: border-bottom-width: border-left-width: border-right-width.
    ok, i would insert this in the table tag?

    and, in the parenthesis i dont need, but is just optional right?

    thank you

  9. #9
    Join Date
    Jun 2005
    Location
    英国
    Posts
    11,876
    Thanks
    1
    Thanked 180 Times in 172 Posts
    Blog Entries
    2

    Default

    You can use border-width to change them all or individually using ordered keywords (border-width: 1px 2px 1px 6px) or, if you (like me) can never remember what order they're supposed to come in, you can use border-left-width, border-right-width, &c. to change each one individually.

    There are three types of CSS: external, embedded and inline, much like Javascript.
    External CSS is included in another text file, commonly with the .css extension and included in the document with <link rel="stylesheet" type="text/css" href="/path/to/file.css"/> in the head of the document.
    Embedded CSS is enclosed within <style type="text/css"></style> tags in the head.
    Inline CSS is set via the style= attribute of any tag. Unlike the other two types, inline CSS does not require you to specify the element to apply it to.
    What you're talking about could be accomplished by inline CSS:
    <table style="border-color:navy; border-width:2px;">
    or external or embedded CSS, either to all tables in the page:
    Code:
    <style type="text/css">
    table {
      border-color: navy;
      border-width: 2px;
    }
    </style>
    or only to that table:
    Code:
    <style type="text/css">
    table.thinborder {
      border-width: 2px;
      border-color: navy;
    }
    </style>
    ...
    HTML Code:
    <table class="thinborder">
    CSS tutorial here.
    Twey | I understand English | 日本語が分かります | mi jimpe fi le jbobau | mi esperanton komprenas | je comprends français | entiendo español | tôi ít hiểu tiếng Việt | ich verstehe ein bisschen Deutsch | beware XHTML | common coding mistakes | tutorials | various stuff | argh PHP!

Bookmarks

Posting Permissions

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