traži:  
 php.com.hr > Source > Kreator tablice

Kreator tablice
 


Omogućuje vam kreirati tablicu s onoliko kolumna koliko odredite.


<?

$b 
113 //broj jedinica
$i 0// incrementor
$z 10// broj kolumna 
?>
<table>
<?
    
while($i $b)
        {
            if(
$i == || $i == $a)
                {
                    echo 
"<tr>";
                    
$a $a $z
                    
$e $a 1
                    if (
$e $b
                        {
                            
$e $b 1
                        }
                }    
                
                echo 
"<td> ".$i." </td>";
            
            if (
$i == $e)
                {
                    echo 
"</tr>";
                }
            
$i++;
        }
?>
</table>


 


Source
 
 © 2004 - 2008 php.com.hr