Oops, try again. It looks like 'hair=>black' is part of $myArray, but it wasn't printed to the page!


// On the line below, create your own associative array:
$myArray = array('hair' => 'black', 'eyes' => 'green', 'hands' => 'long');

  // On the line below, output one of the values to the page:
    echo $myArray['eyes']. '<br />';
  // On the line below, loop through the array and output
  // *all* of the values to the page:
  foreach ($myArray as $x => $y) {
    echo  $x . '<br />';
    echo  $y . '<br />';

why doesn't it work?


It sounds like this post from the old forum it talking about what you are seeing there. It contains an explanation for the bug and two different workarounds that you can use.



same problem here, had bugs like this before