Hello and welcome to our community! Is this your first visit?
Register
Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 14 of 14
  1. #1
    Regular Coder
    Join Date
    Jun 2007
    Location
    Los Angeles
    Posts
    545
    Thanks
    81
    Thanked 5 Times in 5 Posts

    Changing TD vertical size

    I need to increase the vertical size of a TD tag. How can I do this? I need to make it about 4 times as tall as a default TD tag.

    Thanks
    RalphF
    Business Text Messaging Services
    https://www.MobileTextingService.com

  • #2
    Senior Coder
    Join Date
    Aug 2010
    Location
    High Point, NC
    Posts
    3,338
    Thanks
    5
    Thanked 363 Times in 360 Posts
    You mean rowspan="2"?? That merges one row with the next row.

  • #3
    Regular Coder
    Join Date
    Jun 2007
    Location
    Los Angeles
    Posts
    545
    Thanks
    81
    Thanked 5 Times in 5 Posts
    Not sure that would work. See attached image and you can see that I need to increase a row's height to accomadate some vertical text I'm laying down.
    Attached Thumbnails Attached Thumbnails Changing TD vertical size-1.jpg  
    RalphF
    Business Text Messaging Services
    https://www.MobileTextingService.com

  • #4
    Regular Coder
    Join Date
    Oct 2010
    Location
    Florence, MS
    Posts
    486
    Thanks
    10
    Thanked 33 Times in 32 Posts
    Have you tried giving your td an id?

    Code:
    <table id="great">
       <tr>
          <td id="grand1">&nbsp;</td>
          <td id="grand2">&nbsp;</td>
          <td id="grand3">&nbsp;</td>
       </tr>
    </table>
    Notice: If you post a problem and it gets fixed, please remember to go back and place it as solved. ;)
    I always recommend the HEAD First series of books for learning a new coding language. ^_^

  • #5
    Regular Coder
    Join Date
    Jun 2007
    Location
    Los Angeles
    Posts
    545
    Thanks
    81
    Thanked 5 Times in 5 Posts
    I don't understand what an ID would do to the height of a TD tag?
    RalphF
    Business Text Messaging Services
    https://www.MobileTextingService.com

  • #6
    Regular Coder
    Join Date
    Oct 2010
    Location
    Florence, MS
    Posts
    486
    Thanks
    10
    Thanked 33 Times in 32 Posts
    Do you know anything about css?
    Notice: If you post a problem and it gets fixed, please remember to go back and place it as solved. ;)
    I always recommend the HEAD First series of books for learning a new coding language. ^_^

  • #7
    Regular Coder
    Join Date
    Jun 2007
    Location
    Los Angeles
    Posts
    545
    Thanks
    81
    Thanked 5 Times in 5 Posts
    I'm pretty new to CSS.
    RalphF
    Business Text Messaging Services
    https://www.MobileTextingService.com

  • #8
    Regular Coder
    Join Date
    Oct 2010
    Location
    Florence, MS
    Posts
    486
    Thanks
    10
    Thanked 33 Times in 32 Posts
    Ah I see.. well then I suggest going to learn some at http://www.w3schools.com/css/
    Notice: If you post a problem and it gets fixed, please remember to go back and place it as solved. ;)
    I always recommend the HEAD First series of books for learning a new coding language. ^_^

  • #9
    Regular Coder
    Join Date
    Jun 2007
    Location
    Los Angeles
    Posts
    545
    Thanks
    81
    Thanked 5 Times in 5 Posts
    Wow...you could give that answer to everyone instead of trying to actually help them.

    To anyone else who wouldn't mind helping me, I'll repeat my question: I don't understand what an ID would do to the height of a TD tag? I'm asking about what attribute? I can setup the id but I don't know what attribute to use.
    Last edited by rfresh; 11-15-2010 at 05:52 AM.
    RalphF
    Business Text Messaging Services
    https://www.MobileTextingService.com

  • #10
    Regular Coder
    Join Date
    Oct 2010
    Location
    Florence, MS
    Posts
    486
    Thanks
    10
    Thanked 33 Times in 32 Posts
    -_- No sense in being rude. You might want to reread the rules: [url]http://www.codingforums.com/rules.htm[/code]

    The id is for CSS. In other words, in your style tags in css you would put the height attribute to the id thus to the td.
    If you are going to use just html, I suppose putting the height=" " attribute within the td tag would do. Although, I highly suggest not doing that and learning some CSS.
    Notice: If you post a problem and it gets fixed, please remember to go back and place it as solved. ;)
    I always recommend the HEAD First series of books for learning a new coding language. ^_^

  • #11
    New Coder
    Join Date
    Nov 2010
    Posts
    43
    Thanks
    4
    Thanked 2 Times in 2 Posts
    Hi rfresh,

    Here's what you can try. Pop this code in your header:
    Code:
    <style type="text/css">
    
    #specificrowheight
    {
    height:50px;
    }
    
    </style>

    A # tag, specifies that the CSS information is to be used as an ID. A full stop before the name means that it is to be used in a class="...." attribute.

    You can change the height figure, in the form of a percentage, or a pixels figure, as above.

    Then, go to your table, and find the <td> which you're wanting to edit. Change that to:

    Code:
    <td id="specificrowheight">&nbsp;</td>

    This should make that particular section of the table have the height of it's ID, as defined in the CSS in your header.

    That's the difficult way of doing it, you can also just edit for your <td> like so:

    Code:
    <td height="50">&nbsp;</td>

    The figure denotes the height in pixels. Note that if your content exceeds the given height, the <td> will continue to expand, but this might let you make the <td> big enough to fit your text in properly.

    Let me know how it goes!

  • #12
    Regular Coder
    Join Date
    Jun 2007
    Location
    Los Angeles
    Posts
    545
    Thanks
    81
    Thanked 5 Times in 5 Posts
    @stubworth

    OK, so with your help I got the height working but now it's too wide and my width attribute does not seem to work no matter what I try and size the width to!

    See attached image of this code:

    PHP Code:
    #vertical_text {
    writing-modetb-rl;
    -
    webkit-transform:rotate(270deg);
    -
    moz-transform:rotate(270deg);
    -
    o-transformrotate(270deg);
        
    height:66px;
        
    width:10px;

    PHP Code:
    <TD id="vertical_text"
    Attached Thumbnails Attached Thumbnails Changing TD vertical size-1.jpg  
    RalphF
    Business Text Messaging Services
    https://www.MobileTextingService.com

  • #13
    Banned
    Join Date
    Jul 2010
    Posts
    66
    Thanks
    0
    Thanked 1 Time in 1 Post
    Quote Originally Posted by rfresh View Post
    Not sure that would work. See attached image and you can see that I need to increase a row's height to accomadate some vertical text I'm laying down.
    Hi,
    try placing a div inside td and give height to that div i think this should work
    any query let me know

  • #14
    New Coder
    Join Date
    Nov 2010
    Posts
    43
    Thanks
    4
    Thanked 2 Times in 2 Posts
    Double check that the width isn't being affected by any properties you've given to other cells in the table, or within any <div>'s which precede it.

    Post the full code for the page, including any CSS and I can take a look for you.

    Also, ensure that you don't have any spacing elements, e.g. &nbsp; within the table, as this may be affecting the width.

    I'll do my best to help, but really need the full code!


  •  

    Posting Permissions

    • You may not post new threads
    • You may not post replies
    • You may not post attachments
    • You may not edit your posts
    •