I was trying to condense the code, but here is the full version....
Thanks again for any help......I hope you understand the question though.
<?php if($result[count]>0){ ?>
<table width=700 border=0 align="center" cellpadding=2 cellspacing=0>
<tr>
<td colspan=2 valign="bottom">
<font face="arial,verdana,helvetica" size=4>
Products > <?php print stripslashes($detail[catName]); ?>
</font>
<br><br>
<font face="arial,verdana,helvetica" size=2>
Displaying <b><?php print $db->begin; ?> - <?php print $db->end; ?></b> of <b><?php print $db->count; ?></b> Products:</font>
</font>
</td>
<td align="right" valign="bottom">
<font face="arial,verdana,helvetica" size=2>
<?php print $result[next]; ?>
</font>
</td>
</tr>
<?php
$x = 0;
while($list = mysql_fetch_array($result[result])){
?>
<tr>
<td colspan=3>
<img src="images/hr.gif" width=424 height=3 border=0><br>
</td>
</tr>
<?php $array = $list[pPhoto] ? $db->scalePhoto($list[pPhotoWidth], $list[pPhotoHeight]) : array("width" => "75", "height" => "75"); ?>
<tr>
<td valign="top" width=85>
<a href="<?php print $PHP_SELF; ?>?m=product_detail&p=<?php print $list[pID]; ?>"><img src="<?php print $db->productIMGurl; ?>/<?php $list[pPhoto] ? print $list[pPhoto] : print "na.gif"; ?>" width=<?php print $array[width]; ?> height=<?php print $array[height]; ?> border=0></a><br>
</td>
<td valign="top">
<font face="arial,verdana,helvetica" size=2>
<b><a href="<?php print $PHP_SELF; ?>?m=product_detail&p=<?php print $list[pID]; ?>" class="link"><?php print stripslashes($list[pName]); ?></a></b><br>
<?php $list[pTeaser] ? print $db->formatText($list[pTeaser])."<br>" : print ""; ?>
</font>
</td>
<td valign="top" width=100 align="right">
<font face="arial,verdana,helvetica" size=2>
<?php $list[pSalesPrice]>'0' && $list[pSale]=="Y" ? print " <b>Was:</b> <strike>\$$list[pPrice]</strike><br><b>Now:</b> \$$list[pSalesPrice]</font> " : print "<b>Now:</b> \$$list[pPrice]"; ?>
</font>
</td>
</tr>
<?php
$x++;
}
?>
</table>
<?php } else { ?>
<table border=0 width=700 align="center">
<tr>
<td>
<font face="arial,verdana,helvetica" size=2>
<b>Sorry, there are no products found.</b>
</font>
</td>
</tr>
</table>
<?php } ?>