<p>I am currently plowing my way through <a href="http://www-128.ibm.com/developerworks/edu/os-dw-os-php-cake1.html" rel="nofollow noreferrer">IBM's tutorial on CakePHP</a></p>

<p>At one point I run into this snippet of code:</p>

<pre><code>&lt;?php
class Dealer extends AppModel {
    var $name = 'Dealer';
    var $hasMany = array (
        'Product' =&gt; array(
            'className' =&gt; 'Product',
            'conditions'=&gt;, // is this allowed?
            'order'=&gt;, // same thing here
            'foreignKey'=&gt;'dealer_id'
        )
    );
}
?&gt;
</code></pre>

<p>When I run it I get the following error-message: "Parse error: syntax error, unexpected ',' in /Applications/MAMP/htdocs/cakephp/app/models/product.php on line 7"</p>

<p>I'm a n00b at PHP so my question is: is it allowed to make an array with keys without assigned values? Has anybody played around with this tut and know what is up?</p>

It is legal, though as far as I'm aware, you have to explicitly say it's 'empty' by assigning null to it,
```
```
$hasMany = array ('Product' => array(
'className' => 'Product',
'conditions'=> null, // is this allowed?
'order'=> null, // same thing here
'foreignKey'=>'dealer_id'));
```
```
The example you've given sounds very wrong, and probably shouldn't work, as it isn't.