<?php $a = array( new stdClass(), new stdClass(), new stdClass(), ); $i = 0; foreach ($a as $o) { $o = (object) array( 'foo' => 'bar' . $i++, ); } var_dump($a);
You have javascript disabled. You will not be able to edit any code.