Paying $5 for a simple modification of tables

Discussion in 'PHP' started by Hipto, Dec 10, 2009.

  1. #1
    Hipto, Dec 10, 2009 IP
  2. mastermunj

    mastermunj Well-Known Member

    Messages:
    687
    Likes Received:
    13
    Best Answers:
    0
    Trophy Points:
    110
    #2
    Hi,

    I am unable to make out exactly how you want it to be displayed, if you can make a rough draft of it, we can help you do it quickly..
     
    mastermunj, Dec 10, 2009 IP
  3. Hipto

    Hipto Peon

    Messages:
    939
    Likes Received:
    1
    Best Answers:
    0
    Trophy Points:
    0
    #3
    LIKE THIS

    [​IMG]
     
    Hipto, Dec 10, 2009 IP
  4. vengs

    vengs Greenhorn

    Messages:
    77
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    16
    #4
    Is this what u want
    
    $i = 0; 
    $N = 3; //how many per row
    while ($rows = mysql_fetch_array ($results, MYSQL_ASSOC)) {
    
    
    if ( $i % $N == 0 ) { 
    
        echo "<tr>"; 
    
    }
    
    echo "<td width=33% valign=top>
    
    <table width=100% cellpadding=0 cellspacing=0>
    <tr><td align=center>Details</td></tr>
    </table>
    
    </td>";
    
    if ( $i % $N == $N-1 ) { 
         echo '</tr>'; 
       } 
      ++$i;
    
    } // End of while loop.
    
    PHP:
    can use div to make it cleaner...
     
    vengs, Dec 11, 2009 IP