我有变量$CV1
,,......如何在PHP的while循环中获取这些变量的值$CV2
?$CV3
下面是我的代码
$CV1=$fetch->Custom_field1;
$CV2=$fetch->Custom_field2;
$CV3=$fetch->Custom_field3;
$CV4=$fetch->Custom_field4;
$query=mysql_query("select * from customfields where CustomField like '%Invoice%' and CustomLabel != ''");
while($get=mysql_fetch_object($query))
{
$i++;
$Label=$get->CustomLabel;
$CFV='$CV'.$i;
echo "<tr><td>$Label</td><td><input type='text' name='custom_field$i' value='$CFV'></td></tr>";
}
但不是获得 , 的$CV1
值$CV2
。我将变量名本身作为输出。$CV1
,$CV2
等。