Take the 2-minute tour ×
Ask Different is a question and answer site for power users of Apple hardware and software. It's 100% free, no registration required.

I have asked a similar question to this elsewhere on this site, but I thought I’d give this another go in simpler terms.

I am new to Dreamweaver, and I am currently trying to create a simple table of 14 columns. I want them to be the same size.

I currently have the following code. But when I type in dreamweaver, the column widths all move around. I don’t want this, I want the code to wrap. So if for example I input xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx into one of the cells, it expands and reduces the other columns, how do I overcome this?

table.teams{table-layout:fixed; overflow:auto; width:745; align:center; cellspacing:0; cellpadding:0;}

        <table class="teams">
          <tr>
            <td width="5%">&nbsp;</td>
            <td width="5%"></td>
            <td width="8%"></td>
            <td width="8%"></td>
            <td width="8%"></td>
            <td width="8%"></td>
            <td width="8%"></td>
            <td width="8%"></td>
            <td width="8%"></td>
            <td width="8%"></td>
            <td width="8%"></td>
            <td width="8%"></td>
            <td width="5%"></td>
            <td width="5%"></td>
          </tr>  
share|improve this question
add comment

1 Answer 1

This is a better question for Stack Overflow, but this should probably be done with CSS. For this simple example, I specified the width in pixels instead of a percentage. If you must override widths and have particular columns be different widths, then you should could do inline style for the table cells, or put <column /> tags at the top of the table, and specify the width with those (that part wasn't in the JSFiddle). Note that you may need to use CSS to help with line breaks as well if you don't have any spaces in your text.

Example JSFiddle

share|improve this answer
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.