<?php $a = array(1, 2, 3); $values = &$a; foreach ($values as $value) { $values[3] = "bob"; if ($value == "bob") { $values[3] = "We made it into the if"; } } var_dump($values);
You have javascript disabled. You will not be able to edit any code.