title: How to restrict number of images in a row to three?
body: <p>I am populating the images from my database in a table, how to restrict the images to three per row?</p>
  
  <pre><code>&lt;table border="0" align="center" height="25%" width="25%"  &gt;
  &lt;tr&gt;&lt;td align="center" width="50px"  bgcolor="#4b2d0e"&gt;&lt;strong&gt;&lt;font color="#FFFFFF"&gt;Friend List&lt;/font&gt;&lt;/strong&gt;&lt;/td&gt;&lt;/tr&gt;
   &lt;? foreach($Selected as $row)
   {   
       $value = $row['dPath'];
       $imgp =  base_url()."images"."/".$value;
   ?&gt;
   &lt;tr&gt;&lt;td bgcolor="#999999"&gt;
   &lt;strong &gt;&lt;?=$row['dFrindName'].'&lt;/br&gt;';?&gt;&lt;/strong&gt;
   &lt;? if($value!="") { ?&gt;
   &lt;a class="Tab_Link" href="&lt;? echo site_url();?&gt;/friends/View_FProfile/&lt;?=$row['dMember_Id']?&gt;"&gt;&lt;img src="&lt;?=$imgp ?&gt;" name="b1" width="90" height="80" border="0"/&gt;&lt;/a&gt;&lt;br&gt;
   &lt;? } else { ?&gt;
   &lt;a class="Tab_Link" href="&lt;? echo site_url();?&gt;/friends/View_FProfile/&lt;?=$row['dMember_Id']?&gt;"&gt;&lt;img src="../images/us.png" width="90px" height="80px"&gt;&lt;/a&gt;
   &lt;? }?&gt;
   &lt;/td&gt;&lt;/tr&gt;
   &lt;? }}?&gt;
  &lt;/table&gt;
  </code></pre>
  
  <p>This is my table</p>