$result = dbquery("SELECT * FROM ".$db_prefix."article_cats ORDER BY article_cat_name");
$rows = dbrows($result);
if ($rows != 0) {
while ($data = dbarray($result)) {
$num = dbcount("(article_cat)", "articles", "article_cat='".$data['article_cat_id']."'");
echo "<br><a href='".BASEDIR."articles.php?cat_id=".$data['article_cat_id']."'>".$data['article_cat_name']."</a> ($num)";
}}