Adrian Schneider
03-06-2005, 05:02 AM
:disappointed:
I need help getting my foreach statement to work proplerly. This is as close as I could get, $playername displays properly, but $id just displays Array.
foreach ($batsmenarray as $id)
{
foreach ($id as $playername => $playername)
{
eval('$fantasy_cricket_batsmenbit .= "' . fetch_template('fantasy_cricket_batsmenbit') . '";');
}
}
Each value of $batsmenarray is set up like: something[$id][$playername]. I tried following the one of php.net, but it won't work for me for some reason. Any help would be greatly appreciated.
I need help getting my foreach statement to work proplerly. This is as close as I could get, $playername displays properly, but $id just displays Array.
foreach ($batsmenarray as $id)
{
foreach ($id as $playername => $playername)
{
eval('$fantasy_cricket_batsmenbit .= "' . fetch_template('fantasy_cricket_batsmenbit') . '";');
}
}
Each value of $batsmenarray is set up like: something[$id][$playername]. I tried following the one of php.net, but it won't work for me for some reason. Any help would be greatly appreciated.