-4
    $results=mysql_query("SELECT count(*) as total FROM new where date>'$date' and erisim='1'   group by date_format(tarih,'%Y-%m') ");
   $array=mysql_fetch_array($results,MYSQL_ASSOC);

    echo $array[''];

我应该在 $array[''] 中填写什么才能获得每月的计数值?

4

1 回答 1

6
 $results=mysql_query("SELECT count(*) as Total FROM new where year(date)='$ss' and erisim='1'      group by date_format(tarih,'%Y-%m') ");

 while ($row = mysql_fetch_array($results, MYSQL_ASSOC)) {
    echo  $row["Total"] ;
 }
于 2012-08-03T08:41:47.840 回答