Results 1 to 2 of 2

Thread: table border question

  1. #1
    Join Date
    Dec 2004
    Posts
    8
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Question table border question

    Hi. I'm sorry, this might be a fairly simple HTML question, so I apologize, but I can't seem to find the answer anywhere.

    I just switched from PC to Mac, from FrontPage to Dreamweaver, and I'm trying to make a new website layout. When I create a table, how do I make it so that only the left and top border of one cell is visible, while no other borders appear? I know it's possible because it was a simple option in FrontPage but I can't seem to find any option or any way of doing it in DreamWeaver. If someone could tell me how to do it in DreamWeaver or even just give me the HTML for this, I would really appreciate it! Thanks so much!!

    Mayde

  2. #2
    Join Date
    Mar 2005
    Location
    SE PA USA
    Posts
    30,495
    Thanks
    82
    Thanked 3,449 Times in 3,410 Posts
    Blog Entries
    12

    Default

    Quote Originally Posted by mayde
    I just switched from PC to Mac, from FrontPage to Dreamweaver . . .
    Hmm, from the frying pan into the fire . . .

    Most of us 'hacks' here in the forums use a text editor to write all HTML and other code. What you are asking can be done a few different ways and there are other options that influence a table and cell(s) appearance that you haven't specified. Here is a good css method to achieve this, put this style section in the head of the page:
    Code:
    <style type="text/css">
    .borderless {
    border:none;
    }
    .borderless td {
    border:none;
    width:50%; /* this property/value pair optional */
    }
    #left_top {
    border-top:1px solid black;
    border-left:1px solid black;
    }
    </style>
    Here is an example mark-up that could go with it. You can choose which cell gets the special treatment by assigning it the id:
    HTML Code:
    <table class="borderless">
    <tr>
        <td>Hi</td><td id="left_top">&nbsp;there</td>
    </tr>
    <tr>
        <td>mayde</td><td>row 2, cell 2</td>
    </tr>
    
    </table>
    - John
    ________________________

    Show Additional Thanks: International Rescue Committee - Donate or: The Ocean Conservancy - Donate or: PayPal - Donate

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
  •