...

View Full Version : question about table in dreamweaver...



mia_tech
10-19-2008, 10:39 PM
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

gnomeontherun
10-19-2008, 11:08 PM
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?

mlseim
10-19-2008, 11:10 PM
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.

gnomeontherun
10-19-2008, 11:20 PM
Wouldn't it be necessary to clear the margin and padding for the body as well with CSS?


body {
margin: 0;
padding: 0;
}

Also just checked that inline style for <td> like that does work.

mia_tech
10-20-2008, 12:05 AM
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

_Aerospace_Eng_
10-20-2008, 01:13 AM
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.

mia_tech
10-20-2008, 01:21 AM
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

_Aerospace_Eng_
10-20-2008, 02:32 AM
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.


html, body {
margin:0;
padding:0;
}

h1 {
margin:0;
padding:0;
}
An h1 by default has a top margin.

mia_tech
10-20-2008, 12:22 PM
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...

tagnu
10-20-2008, 12:39 PM
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.

mia_tech
10-20-2008, 02:02 PM
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

abduraooft
10-20-2008, 02:17 PM
What's the point in seeking help without following the suggestions so far?
Fix the errors in your markup (http://validator.w3.org/check?uri=http&#37;3A%2F%2Fpctechtips.org%2Ftest%2FUntitled-2.html&charset=%28detect+automatically%29&doctype=Inline&group=0) first!

mia_tech
10-20-2008, 02:35 PM
by fixing the errors, you mean validating the code?... yes I have to take some time, and actually do that



EZ Archive Ads Plugin for vBulletin Copyright 2006 Computer Help Forum