How can I reference an array item from a function in php? I would also like to make that array item null. 

Is this correct? 

```
 <?php
    $array = array();
    function nullItem($item) {
        $item = null;
    }
    class foo
    {
        function do_foo()
        {
            echo "Doing foo.";
        }
    }
    $array[0] = new foo;
    var_dump($array);
    nullItem($array[0]);
    var_dump($array);
?>

```