www.webdeveloper.com
Results 1 to 10 of 10

Thread: omgawd

  1. #1
    Join Date
    Jan 2008
    Location
    Palo Alto, California
    Posts
    32

    omgawd

    why does

    Code:
    <table>
      <td>
           <tr> a </tr>
           <tr> b </tr>
       </td>
      <td>
           <tr> c </tr>
           <tr> d </tr>
       </td>
    </table>
    come out like

    a b c d


    when it should look like...

    a c
    b d

    ???


  2. #2
    Join Date
    Jun 2003
    Location
    here
    Posts
    4,551
    swap your tr's and td's around.

  3. #3
    Join Date
    Oct 2005
    Posts
    481
    Because to get the result that you want, the code should be:

    Code:
    <table>
      <tr>
           <td> a </td>
           <td> c </td>
       </tr>
      <tr>
           <td> b </td>
           <td> d </td>
       </tr>
    </table>
    hth

  4. #4
    Join Date
    Dec 2005
    Location
    American, living in Toronto, ON. CANADA
    Posts
    6,746
    "<tr>" cannot exist inside of a "<td>", and "<td>" canot exist anywhere but inside of a "<tr>".. more-or-less the browser is trying it's best to render something..

  5. #5
    Join Date
    Jan 2008
    Location
    Palo Alto, California
    Posts
    32
    Quote Originally Posted by WebJoel
    "<tr>" cannot exist inside of a "<td>", and "<td>" canot exist anywhere but inside of a "<tr>".. more-or-less the browser is trying it's best to render something..
    ohh no wonder i am nub

    this sucks cuz

    i need to generate more and more columns... not rows arg

    im using some code on the backend to try to make columns and stuff oh well

    now im going to have like 25 for loops (using XQuery!!)


  6. #6
    Join Date
    Jan 2008
    Location
    Palo Alto, California
    Posts
    32
    ng

  7. #7
    Join Date
    Feb 2008
    Posts
    29
    Yes you can't put a table row inside of a table division but you can put a table inside of a table row if I'm not mistaken.

    Thanks, Death

  8. #8
    Join Date
    Dec 2005
    Location
    American, living in Toronto, ON. CANADA
    Posts
    6,746
    Yes you can't put a table row inside of a table division ...
    You might want to call "<td>" "table data" cells and not "table divisions", -lest we confuse newcomers.

    Nesting tables, -can be done but it's a bain and should be avoided.

  9. #9
    Join Date
    Feb 2008
    Posts
    29
    Lol, and this is why I hate tables.

    Thanks, Death

  10. #10
    Join Date
    Dec 2005
    Location
    American, living in Toronto, ON. CANADA
    Posts
    6,746
    'nested tables' had a particularly deletarious effect upon WIN-98 2nd Edition with minimal system RAM. I used to have ~, and any page with 3 or 4 'table nestings' almost always resulted in a lovely BSOD. A 'stack overflow' was the official cause. Increasing the RAM helped but Win-98 had a 'software bug' that created this suseptability.

    I much prefer using DIVisions, -they were made for and intended for just such nesting, and as such, work the processor much less.

    And, -I have long since switched to XP (and Linux).

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Posting Permissions

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



Recent Articles