Help!!!

liunx

Guest
can someone explain to me how td widths work??? I'm having trouble laying out my page. I did it in dreamweaver so I'm not really understanding the code. I've been playing around with it the whole day and I can't get it. Please advise. If you know any tutorials on this please attach the site. Thanks again!!!<!--content-->a good site for general tutorials is webmonkey.com, or davesite.com<br />
<br />
table widths<br />
the width of the table is determined by the attribute "width". to use it, insert it into the table tag like this:<br />
<br />
<table width=><br />
<br />
...and put your width after the equals sign. the width you specify will be the width of the table in pixels. thus, if you are viewing your site at a screen resolution of 800x600, and you enter 400 for your table width, you'll be looking at a table that is exactly half the width of your screen. 600 pixels would be 3/4 the width of your screen (at 800x600 resolution only). higher and lower resolutions will obviously have different widths. for example, a resolution of 1024x768 with a table taking up half the screen would have a table tag like this:<br />
<br />
<table width=512><br />
<br />
...to use percentages, do it like this:<br />
<br />
<table width="75%"><br />
<br />
(put your percentage inside quotation marks.)<br />
<br />
100% will span the length of the user's screen, no matter what resolution they are viewing your site at. one thing to keep in mind, however, is that margins will reduce "100%" to something more like "100% minus margin width (typically 10 pixels)," although you can always go with percentages over 100 in order to get around this. i use "101.5%" or something like that.<br />
<br />
table height<br />
don't even bother. specifying in percentage will only result in a percentage amount of the portion of your site that is visible in your browser, between the toolbar, etc. (top) and the status bar (bottom). this is extremely unreliable. using fixed amounts (e.g., <table height=235>) will only result in the size you specify if your content (text, etc.) takes up an equal amount of space or less. this is why it's not generally recommended to bother specifying the table height. it's just too unreliable that way.<br />
<br />
hope that helps somewhat.<!--content-->thanks for the info...where I'm having trouble is laying out my page in a table using %'s. Like putting %'s for individual cells. I've never done this so I'm trying to figure out how to do it. I'd tried it in Dreamweaver 4 but it was only in pixels...<!--content-->use <td width="xx%"><br />
<br />
i could be wrong about this next part. it's been awhile since i've actually done this.<br />
<br />
the percentage will be the percentage of the table width. so, if your table is 50% of the screen, and your cell is 50% of the table, the cell will be 25% (50% x 50%) of the screen. it's a good idea not to mix fixed widths and percentages.<!--content-->transmothra has said all the basic ideas of width/heights. To get any better answers, could you please post your code, or link to the site, and describe what wrong / how you would like it to look? That'd help plenty! :D :D<!--content-->
 
Back
Top