Jump to content

[SOLVED] using a loop help


lebedev9114

Recommended Posts

Hi guys , i need some help. I have this loop :

while ($row = mysql_fetch_assoc($Result)) { ?>

<th><?php echo "<a href=http://".$row['booking_site'].">";

echo $row['bookingname'];

echo "</a>";

?>

</th>

<th><?php echo number_format($row['com'],0,'.',','); ?></th>

<th><?php echo number_format($row['AlexaRanking'],0,'.',','); ?></th>

 

'com' - is an integeir

i need help with replacing this $row['com'] IF the number is 0  with a DASH (-) how may i include an if an else statement or a prematch inside or outside the while loop?

Link to comment
https://forums.phpfreaks.com/topic/178204-solved-using-a-loop-help/
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.