Re: problem regarding for rech loop
You don't need the foreach. The while ... contruct will fetch each row for you.
if ( $count )
{
while( $rows = odbc_fetch_array( $result))
{
echo "<h3>".$rows['companyname']."</h3>";
echo '</br>';
echo "<b>Contact Number : </b> ".$rows['call'];
echo '</br>';
echo "<b>Address : </b>".$rows['Address'];
echo '</br>';
echo "<b>Contact Person : </b> ".$rows['contactperson'];
echo '</br>';
echo "<b>Email ID : </b>".$rows['email'];
echo '</br>';
echo "<b>Website : </b> ".$rows['website'];
echo '</br>';
echo "<b>Additional Information : </b> \n ".$rows['detail'];
}
//close the connection
[/code]
Good luck,
Barry.
Subject
Written By
Posted
December 09, 2012 11:45PM
Re: problem regarding for rech loop
December 10, 2012 06:41PM
Sorry, you can't reply to this topic. It has been closed.
Content reproduced on this site is the property of the respective copyright holders.
It is not reviewed in advance by Oracle and does not necessarily represent the opinion
of Oracle or any other party.