0

I am working with Dreamweaver CS4 and am still in the learning process of CSS and HTML and Dreamweaver. I hope I can explain this the way that it is in my head.... I have made a table on one page, and I want to make a table on another page that is a different size. I have the code in the style.css folder, how do I place the code for the other table and keep them separate. I certainly hope this makes sense.

4
Contributors
3
Replies
4
Views
7 Years
Discussion Span
Last Post by nkdweb
0

Very VERY easy.

Use classes. If im getting what you saying right. You currently using something like this

table {
width: 200px;
border: 1px solid #000
}

So if you had to use classes it would change to this;

table.shortwidth {
width: 200px;
border: 1px solid #000
}

table.standard {
width: 300px;
border: 1px solid #000
}

Then just assign them in your HTML

<table class="standard">
<tr>
 <td>
  &npsp;
 <td>
</tr>
</table>
0

Good idea macneato !

This is the way to use CSS

Normally I do not use table and sometimes forget that table tag support CSS on it! and not just for border or colors

0

You can also use inline CSS where you created the table, like below

<table style="width:20%">
-
-
-</table>

<table style="width:50%">
-
-
-
</table>

This topic has been dead for over six months. Start a new discussion instead.
Have something to contribute to this discussion? Please be thoughtful, detailed and courteous, and be sure to adhere to our posting rules.