" . "" . "
" . "Eco-\$mart Product List - $name" . "$today" . "
"); echo("" . "" . "" . ""); $dbcnx = @mysql_connect('mysql.plainhost.com', 'ecosmar_ecosmart', 'ecoman1'); mysql_select_db('ecosmar_products', $dbcnx); $getit = mysql_query("SELECT item,sku,list,retail,special,dealer,dealer_lo,unit,lo_units,cs,min,up_date,description FROM price WHERE item LIKE '$itemstart%' ORDER BY item"); if(!$getit){ echo("

Could not Get Product List.
Error: ".mysql_error()."

"); }else{ $numrows = mysql_num_rows($getit); if($numrows < 1){ echo("

No Products Showing in $name.

"); }else{ $county = 0; $pagecount = 1; while($row = mysql_fetch_array($getit)){ $not="off"; $item=$row['item']; $sku=$row['sku']; $list=$row['list']; $retail=$row['retail']; $special=$row['special']; $dealer=$row['dealer']; $dealer_lo=$row['dealer_lo']; if($list+$retail+$special+$dealer+$dealer_lo == 0){ $not="on"; } if($item{0} != "9" and $not!="on"){ $mounty = $county/26; if(is_int($mounty) and $mounty != 0){ $pagecount = $pagecount+1; echo("
ItemskuListRetailSpecialWholesaleWhols LoUnitLo Unit
" . "
©2010 Eco-\$mart Inc." . "Eco-\$mart Product List - $name" . "Page $mounty
" . "
" . "" . "
" . "Eco-\$mart Product List - $name" . "$today" . "
"); echo("" . "" . "" . ""); }//dividend is an integer $founty = $county/2; if(is_int($founty)){ $fellow = "background-color:#eeeeee;"; }else{ $fellow = "background-color:white;"; } $unit=$row['unit']; $lo_units=$row['lo_units']; if($lo_units == "None" or $lo_units == "none" or $lo_units == ""){ $lo_units="0"; } $cs=$row['cs']; if($cs == "None" or $cs == "none" or $cs == ""){ $cs="0"; } $min=$row['min']; if($min == "None" or $min == "none" or $min == ""){ $min="0"; } $up_dater=substr($row['up_date'],2,6); $p_dater = str_split($up_dater,2); $up_date = $p_dater[1]."-".$p_dater[2]."-".$p_dater[0]; $description=$row['description']; echo("" . "" . "" . "" . "" . ""); }//not trashed $county=$county+1; }//while }//there are rows }//big else echo("
ItemskuListRetailSpecialWholesaleWhols LoUnitLo Unit
$item$sku $list $retail $special $dealer $dealer_lo $unit $lo_units
$description   [Cs:$cs] [Min:$min] [Upd:$up_date]
" . "
©2010 Eco-\$mart Inc." . "Eco-\$mart Product List - $name" . "Page $pagecount
" . "
"); ?>