I am trying to show a count of all applications stored in a database with the status of 1
.
Here is my UPDATED code:
$result=mysql_query("SELECT * FROM member ")or die('You need to add an administrator ' );
$counter = mysql_query("SELECT COUNT(*) as personID FROM member where state='1' ");
$row = mysql_fetch_array($result);
$personID = $row['personID'];
$num = mysql_fetch_array($counter);
$countadmin = $num["personID"];
However this isn't showing anything when I echo `$countadmin'
Can anyone help