新手请问:调用函数时无任何输出结果
程序员文章站
2024-01-30 10:14:10
...
新手请教:调用函数时无任何输出结果
函数:
function jingdian($dq_id)
{
$result_jingdian = mysql_query("select count(*) as shuliang from jingdian where jd_diqu=".$dq_id, $con);
$row_jingdian = mysql_fetch_array($result_jingdian);
return $row_jingdian["shuliang"];
}
函数是写在整个页面最上面的。
调用:
while($row = mysql_fetch_array($result))
{
echo "
函数:
function jingdian($dq_id)
{
$result_jingdian = mysql_query("select count(*) as shuliang from jingdian where jd_diqu=".$dq_id, $con);
$row_jingdian = mysql_fetch_array($result_jingdian);
return $row_jingdian["shuliang"];
}
函数是写在整个页面最上面的。
调用:
while($row = mysql_fetch_array($result))
{
echo "