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 7 of 7
  1. #1
    Regular Coder
    Join Date
    Jul 2002
    Posts
    108
    Thanks
    0
    Thanked 0 Times in 0 Posts

    table in a table

    Hi,

    I know how to 'draw' the basic lines of a table and how to divide cells and stuff, but how can I create a table inside an existing table with a different color or different border?

    Thanks!

  • #2
    Senior Coder
    Join Date
    Jun 2002
    Location
    Wichita
    Posts
    3,880
    Thanks
    0
    Thanked 0 Times in 0 Posts
    It's called "nesting", you place the table inside a TD element of another table.

    Code:
    <table>
      <tr>
        <td>
          <table>
          ...
          </table>
        </td>
      </tr>
    </table>

  • #3
    Regular Coder
    Join Date
    Aug 2002
    Location
    Sacramento, California
    Posts
    132
    Thanks
    0
    Thanked 0 Times in 0 Posts
    You can nest tables inside of tables inside of table if u want
    example

    Code:
    <html>
    <body>
    <table>
    <tr>
    <td>
    <table>
    <tr>
    <td>
    <table>
    <tr>
    <td>
    Blah Blah Blah Blah....Blah BlahBlah BlahBlah Blah...Blah BlahBlah Blah Blah Blah Blah Blah Blah Blah Blah BlahBlah Blah Blah Blah.
    </td>
    </tr>
    </table>
    </td>
    </tr>
    </table>
    </td>
     </tr>
    </table>
    Hairynugs


    Simple is best.

  • #4
    Regular Coder
    Join Date
    Jul 2002
    Posts
    108
    Thanks
    0
    Thanked 0 Times in 0 Posts
    And how do I put an image in? Ive tried it this way, but then the Image doesn't want to center (align), and when I make it absolute it jumps all over the place...

  • #5
    Senior Coder
    Join Date
    Jun 2002
    Location
    Wichita
    Posts
    3,880
    Thanks
    0
    Thanked 0 Times in 0 Posts
    <img src="someoldthing.jpg" style="display:block; text-align: center;">

  • #6
    Regular Coder
    Join Date
    Jul 2002
    Posts
    108
    Thanks
    0
    Thanked 0 Times in 0 Posts
    does the <style: display="block"> tag insert also work for other things than images? Is it possible to lock the position of everything on your site (like tables) this way?

    Thanks for the quick responses, it helped!

  • #7
    Regular Coder
    Join Date
    Aug 2002
    Location
    Sacramento, California
    Posts
    132
    Thanks
    0
    Thanked 0 Times in 0 Posts
    Yes you can use the STYLES to position pretty much every thing

    say u have an image u want 200px from the top!

    Code:
    <img src="image.jpg" style="top:200px;">
    same for tables
    Code:
    <table style="top:200px; left:100;">
    <tr><td>Blah Blah Blah...</td></tr>
    </table>

    same thing for bottom left and right to learn more about STYLE click on the following link!http://www.w3.org/TR/REC-CSS2/visure...tioning-scheme
    Last edited by hairynugs6382; 09-07-2002 at 01:01 AM.
    Hairynugs


    Simple is best.


  •  

    Posting Permissions

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