我想将$ mine的值从一到二传递给任何人可以帮助我
function one($one_nr) {
global $db;
$query = "SELECT one_ward FROM ward WHERE ward_nr =".$db->qstr($one_nr);
$exe = $db->Execute($query);
while ($row = $exe->FetchRow()) {
$get_ward = $row['one_ward'];
}
$mine = two($get_ward);
}
function two($mine) {
var_dump($mine);die;
global $db;
}
答案 0 :(得分:0)
function one($one_nr) {
global $db;
$query = "SELECT one_ward FROM ward WHERE ward_nr =".$db->qstr($one_nr);
$exe = $db->Execute($query);
while ($row = $exe->FetchRow()) {
$get_ward = $row['one_ward'];
}
$mine = two($get_ward);
}
function two($mine) {
return var_dump($mine);
}