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 13 of 13
  1. #1
    Regular Coder
    Join Date
    Jul 2007
    Location
    FL, USA
    Posts
    153
    Thanks
    13
    Thanked 0 Times in 0 Posts

    question about table in dreamweaver...

    guys how could I eliminate the space between the top of the table and the beginning of the page, so the table start at the very top of the page.... also if I just wanted to increase the size of the border of a cell and not the table how could I do that, I've been trying to select the cell, but when I change the border property it changes the border for the whole table
    thanks
    ____________________
    www.pctechtips.org

  • #2
    Senior Coder gnomeontherun's Avatar
    Join Date
    Sep 2007
    Location
    Houston
    Posts
    2,846
    Thanks
    10
    Thanked 238 Times in 229 Posts
    Border applies to the entire table unless you apply specific CSS class for that cell to have a different border. Also by default a page has some space around the edges so that things don't bump against the edges, you will have to change the page's margin and padding to 0.

    You aren't trying to use a table for layout are you?
    jeremy - gnomeontherun
    Educated questions often get educated answers, and simple questions often get simple answers.

  • #3
    Master Coder
    Join Date
    Jun 2003
    Location
    Cottage Grove, Minnesota
    Posts
    9,464
    Thanks
    8
    Thanked 1,085 Times in 1,076 Posts
    I'm stabbing at this ... you should show us a link to your page.

    To make it go to the top ...
    <table valign="top">

    An inline CSS might affect the cell border for just that <td> .... (not sure) ...

    <td style="border:2px solid #000;">

    It's been so long since I've used <table>s ... not sure about IE vs FF.

  • #4
    Senior Coder gnomeontherun's Avatar
    Join Date
    Sep 2007
    Location
    Houston
    Posts
    2,846
    Thanks
    10
    Thanked 238 Times in 229 Posts
    Wouldn't it be necessary to clear the margin and padding for the body as well with CSS?
    Code:
    body {
    margin: 0;
    padding: 0;
    }
    Also just checked that inline style for <td> like that does work.
    jeremy - gnomeontherun
    Educated questions often get educated answers, and simple questions often get simple answers.

  • #5
    Regular Coder
    Join Date
    Jul 2007
    Location
    FL, USA
    Posts
    153
    Thanks
    13
    Thanked 0 Times in 0 Posts
    Quote Originally Posted by mlseim View Post
    I'm stabbing at this ... you should show us a link to your page.

    To make it go to the top ...
    <table valign="top">

    An inline CSS might affect the cell border for just that <td> .... (not sure) ...

    <td style="border:2px solid #000;">

    It's been so long since I've used <table>s ... not sure about IE vs FF.
    no the valign="top", didn't work, I don't think that dreamweaver is recognizing that tag property... the table already have an align="center" property, but I'm trying to eliminate the gap between the table and the top of the page, I'll take care of this first and then worry about the cell border
    here's the link to the page
    http://pctechtips.org/test/Untitled-2.html
    thanks
    ____________________
    www.pctechtips.org

  • #6
    Supreme Master coder! _Aerospace_Eng_'s Avatar
    Join Date
    Dec 2004
    Location
    In a place far, far away...
    Posts
    19,291
    Thanks
    2
    Thanked 1,043 Times in 1,019 Posts
    In Dreamweaver click on Commands > Apply Source Formatting. The layout should be okay. Clearly you haven't read the link in my signature titled "Why Tables for Layout is Stupid?". I suggest you do. Tables are not meant for page layout.
    ||||If you are getting paid to do a job, don't ask for help on it!||||

  • #7
    Regular Coder
    Join Date
    Jul 2007
    Location
    FL, USA
    Posts
    153
    Thanks
    13
    Thanked 0 Times in 0 Posts
    Quote Originally Posted by _Aerospace_Eng_ View Post
    In Dreamweaver click on Commands > Apply Source Formatting. The layout should be okay. Clearly you haven't read the link in my signature titled "Why Tables for Layout is Stupid?". I suggest you do. Tables are not meant for page layout.
    actually I read it a long time ago, and I know is true, all the clutter that table bring, it makes pages more difficult to load, etc... and the layout should be done in css, (on a side note dreamweaver has lots of support for css) but until times allows I won't get more involved in css, so tables would have to do for me right now... going back to the topic, what does "apply source formatting" does, as I've done just that, but I see not difference
    thanks
    ____________________
    www.pctechtips.org

  • #8
    Supreme Master coder! _Aerospace_Eng_'s Avatar
    Join Date
    Dec 2004
    Location
    In a place far, far away...
    Posts
    19,291
    Thanks
    2
    Thanked 1,043 Times in 1,019 Posts
    It formats the code so its more readable. There are some errors in your code. Likely due to improper use of the design view. Go to http://validator.w3.org to validate your code. When I used the Apply Source Formatting option your layout looked okay. The gap at the top was gone as was the gap below the menu. Also add this to your CSS to fix additional whitespace issues.

    Code:
    html, body {
    margin:0;
    padding:0;
    }
    
    h1 {
    margin:0;
    padding:0;
    }
    An h1 by default has a top margin.
    ||||If you are getting paid to do a job, don't ask for help on it!||||

  • #9
    Regular Coder
    Join Date
    Jul 2007
    Location
    FL, USA
    Posts
    153
    Thanks
    13
    Thanked 0 Times in 0 Posts
    well, after applying those setting and the css code, it looks good on the design view, but when preview in browser FF/IE is still showing the separation at the top and also below the menu...
    thanks
    ____________________
    www.pctechtips.org

  • #10
    Regular Coder
    Join Date
    Nov 2007
    Location
    127.0.0.1
    Posts
    348
    Thanks
    26
    Thanked 40 Times in 39 Posts
    There's an &nbsp; which gets pushed outside the table on preview.
    <table width="800" border="0" align="center" cellpadding="0" cellspacing="0" >
    <tr>
    <td><img src="negativevideocard04100071.jpg" width="800" height="150" /></td>
    </tr>

    <tr> &nbsp;
    </td>
    </tr>
    <tr>
    Always validate your code.
    Blog Charity:Water
    WhatisWrongWith.me/tagnu - Send me anonymous feedback.

  • Users who have thanked tagnu for this post:

    mia_tech (10-20-2008)

  • #11
    Regular Coder
    Join Date
    Jul 2007
    Location
    FL, USA
    Posts
    153
    Thanks
    13
    Thanked 0 Times in 0 Posts
    thanks that solved the issue with the table been separated from the top of the page, but I've been looking at the css code for the menu, and there's no way I can get rid off the white space....


    http://pctechtips.org/test/Untitled-2.html
    thanks
    ____________________
    www.pctechtips.org

  • #12
    Supreme Master coder! abduraooft's Avatar
    Join Date
    Mar 2007
    Location
    N/A
    Posts
    14,851
    Thanks
    160
    Thanked 2,223 Times in 2,210 Posts
    Blog Entries
    1
    What's the point in seeking help without following the suggestions so far?
    Fix the errors in your markup first!
    The Dream is not what you see in sleep; Dream is the thing which doesn't let you sleep. --(Dr. APJ. Abdul Kalam)

  • #13
    Regular Coder
    Join Date
    Jul 2007
    Location
    FL, USA
    Posts
    153
    Thanks
    13
    Thanked 0 Times in 0 Posts
    by fixing the errors, you mean validating the code?... yes I have to take some time, and actually do that
    thanks
    ____________________
    www.pctechtips.org


  •  

    Posting Permissions

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