Trying to run a count query but for some reason it's not echo-ing anything out. When I put the same query into phpmyadmin I get a value so I don't understand..
$CountQuery = "SELECT COUNT(productname) as a FROM tblproducts";
$CountResult = mysql_query($CountQuery) or die(mysql_error().'<br />'.$CountQuery);
while($rowc = mysql_fetch_array($result)){
$prodsqlcount = $rowc['a'];
}
echo $prodsqlcount;