I made a mistake while using foreach on an array but the code still worked.
Array ( [0] => u_fname [1] => u_showname )
I then did
foreach ($cfentarr as $k => $tx ) {
if($k=='u_fname')$memname=$row2[$tx];
}
$row2 is a mysql array...
Spot my mistake in the foreach - $k only ever equals the array index number - it never equals "u_fname".
BUT I have no problem getting $memname set here - but it shouldn't be !!
I've corrected my code but above behaviour is weird
Or am I misunderstanding what => does on indexed arrays?