If you are going to show the number of rows in one table, why not show the number of rows in *EACH* table???
And this is a terrible way to find the number of rows:
Code:
$result = mysql_query("SELECT * FROM pts_ads");
$num_rows = mysql_num_rows($result);
If you had millions of records in that table, it would take a *LONG* time to run!
So...
Code:
$query = "SHOW TABLES FROM paidtosi_crusad";
$result = mysql_query($query);
$num_of_tables = mysql_num_rows($result);
echo $num_of_tables."<br />";
while($onetable = mysql_fetch_array($result))
{
$tblname = $onetable[0];
$sql = "SELECT COUNT(*) FROM `" . $tblname . "`";
$tresult = mysql_query($sql);
$tcount = mysql_fetch_array($tresult);
echo $tblname . ": " . $tcount . " records<br/>\n";
}
Remembering, please, that I don't use PHP. So I could well have a PHP typo in that.