array_diff does not work PHP
<pre><code>Array 1 ($allmodels)
Array ( [0] =&gt; Array ( [id] =&gt; 6 ) 
        [1] =&gt; Array ( [id] =&gt; 7 ) 
        [2] =&gt; Array ( [id] =&gt; 8 ) ) 

Array 2 ($existmodels)
Array ( [0] =&gt; Array ( [id] =&gt; 6 ) 
        [1] =&gt; Array ( [id] =&gt; 4 ) 
        [2] =&gt; Array ( [id] =&gt; 7 ) 
        [3] =&gt; Array ( [id] =&gt; 5 ) )
</code></pre>

<p>What I want as output array is(get the remaining models using $allmodels - $existmodels )</p>

<pre><code>Array ( [0] =&gt; Array ( [id] =&gt; 8 ))
</code></pre>

<p>I tried </p>

<p><code>array_diff($allmodels,$existmodels);</code> AND <code>array_diff_assoc($allmodels,$existmodels);</code> which both result </p>

<blockquote>
  <p>Array ( )</p>
</blockquote>

<p>Can anyone tell me how can I get it done ?</p>
