fork download
  1. <?php
  2. $arr = array(
  3. '0' => "ноль",
  4. '1' => "один",
  5. '2' => "два");
  6.  
  7. foreach($arr as $key => $val) {?>
  8. <tr>
  9. <td><?php echo $key;?></td>
  10. <td><?php echo $val;?></td>
  11. </tr>
  12. <?php }?>
Success #stdin #stdout 0.02s 52432KB
stdin
Standard input is empty
stdout
<tr>
<td>0</td>
<td>ноль</td>
</tr>
<tr>
<td>1</td>
<td>один</td>
</tr>
<tr>
<td>2</td>
<td>два</td>
</tr>