altering width of a <td> with css?

liunx

Guest
Hello everybody,
I'm creating a little webpage using a table as my layout. Attached to this page I have a CSS file linked. I would like to change the width of my navigation bar which is situated down the left side of my page. Unfortunately, thus far I've been unable to get the width to change. Here is my code:

css:

#navigation
{
background-color:#FFFFFF;
width:100px;
}


html:

<table class="maintable">

<tr>
<td colspan="2">
<img src=http://www.webdeveloper.com/forum/archive/index.php/"images/title.gif" />
</td>
</tr>

<tr>

<td id="navigation">
kjslfjsal;fkjsaflks
</td>

<td id="mainbody">
sdfjksaf;sa
</td>

</tr>

</table>


Although the width is set to 100, it infact takes up the vast majority of the page. I'd be grateful for any help. Thanks.As tables aren't for layout your ability to control cell size is limited. If you go breaking the rules then you can't very well complain about the results.
 
Back
Top