<?php $ary=array("name","egineer","sonny","tonny","pingk","apple","phone","clone","pink","colle"); foreach($ary as $key=>$value){ $key=$key+1; if($key%2==1){echo '';} ?> <?php echo $key.":". $value;?> <?php if($key%2==0){echo '';} }; ?> second_one <?