<?php $array = array(); $obj = new stdClass(); function foo( $foo ) { $foo[0]['key'] = 'value'; $foo[1]->key = 'value'; } foo( array( &$array, $obj ) ); var_dump( $array ); var_dump( $obj );
You have javascript disabled. You will not be able to edit any code.