How can I set a fixed width on a table in Dreamweaver CS3?

Discussion in 'HTML & Website Design' started by TransPersonal, Oct 16, 2008.

  1. #1
    The title is the question.

    I want to be able to type inside the table without having it expand when the text reached the edge. Instead I want the width to be fixed so that the text automatically goes on to the next line every time.

    Thanks.
     
    TransPersonal, Oct 16, 2008 IP
  2. LeetPCUser

    LeetPCUser Peon

    Messages:
    711
    Likes Received:
    14
    Best Answers:
    0
    Trophy Points:
    0
    #2
    Go to the code and where it says <table> change it to <table width=x> where x is how wide in pixels you want it to be.
     
    LeetPCUser, Oct 16, 2008 IP
  3. TransPersonal

    TransPersonal Peon

    Messages:
    48
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    0
    #3
    Didn't work:(. Here's the code:

    <table width="342" height="264" border="1">
    <tr>
    <td>&nbsp;</td>
    </tr>
    </table>

    I did what you said and the table still continues to expand when the text reaches it's border instead of going on to the next line.
     
    TransPersonal, Oct 16, 2008 IP
  4. tonyrocks

    tonyrocks Active Member

    Messages:
    1,574
    Likes Received:
    50
    Best Answers:
    0
    Trophy Points:
    88
    #4
    Try a no-wrap style. You should really brush up on Cascading Style Sheets for styling your sites:

    http://www.w3schools.com/css/

    Easier to fix stuff in the long run :)
     
    tonyrocks, Oct 16, 2008 IP
  5. Debt Reduction

    Debt Reduction Peon

    Messages:
    248
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    0
    #5
    I advise you to use no-wrap style.

    If still does not work then try to give width and height without double quotes.
     
    Debt Reduction, Oct 17, 2008 IP