0
a.php只會(配置文件):
<?php
$a = array('name'=>'wine[$index][name]',
'value'=>'wine[$index][value]'
)
?>
B.php:
include_once(a.php)
...
//for simple
$index = 0;
$b = $a;
//actual code like
foreach($data as $index=>$value)
$b += $a
我知道這個例子將無法正常工作,只是爲了交代,我想要是否有可能(如果可能的話,怎麼做?)在$ b = $ a時延遲變量$ index來取值?
@Relax爲$ B = $一個與$ b等於$ a或你要爲$ B與$ a的值? – 2010-04-02 17:21:25
後者,實際代碼就像foreach($ data爲$ index => $ value)$ b + = $ a – Edward 2010-04-03 03:44:39