title: MongoDB/PHP unset an array by key
body: <p>I have a document that has a nested array.  I want to delete an item in the array by it's key value.  I've tried doing an update with:</p>
  
  <p><code>array('$unset' =&gt; array('item.key' =&gt; 1))</code></p>
  
  <p><code>array('$pull' =&gt; array('item.key' =&gt; 1))</code></p>
  
  <p>Doing, <code>$unset</code> , kept the key but nulled out the value, I want to get rid of it entirely.  Pull didn't do anything.</p>
  
  <p>Any suggestions?</p>
  
  <p>Thank you!</p>