The following code creates list with the elements of an array. The blue colored code segments deserves attention.
<html>
<body>
<?php
$arr = array("Sim","Sum","Shis");
$count = 0;
?>
<ul>
<?php while($count < count($arr)) :?>
<li> <?php echo $arr[$count]; $count++; ?> </li>
<?php endwhile;?>
</ul>
</body>
<html>
19 June 2009
php code inside HTML tag
Subscribe to:
Post Comments (Atom)
0 Comments:
Post a Comment