title: simplexml_load_file remove duplicate keys
body: <p>I'm loading an XML file, which happens to have duplicate items in it.
  I wish to remove those, but trying so throws me an error:</p>
  
  <blockquote>
    <p>Message:  It is not yet possible to assign complex types to properties</p>
  </blockquote>
  
  <p>The return of the xml function is off course an object, where the items are stored in an array.
  Those items are object again, so I guess this makes it a bit harder to check against duplicates.</p>
  
  <p>I've tried fixing this with:</p>
  
  <p><code>array_unique((array) $XMLObject);</code></p>
  
  <p>But that doesn't seem to work.</p>
  
  <p>Anyone got an idea?</p>
  
  <p>Here's my xml-object:</p>
  
  <pre><code>object(SimpleXMLElement)#19 (5) {
    ["title"]=&gt;
    string(33) "P2000 alarmeringen Heel Nederland"
    ["link"]=&gt;
    string(26) "http://www.p2000zhz-rr.nl/"
    ["description"]=&gt;
    string(54) "Hier vind u alle P2000 alarmeringen van Heel Nederland"
    ["lastBuildDate"]=&gt;
    string(31) "Mon, 10 Sep 2012 22:19:28 +0000"
    ["item"]=&gt;
    array(300) {
      [0]=&gt;
      object(SimpleXMLElement)#22 (5) {
        ["title"]=&gt;
        string(4) "test"
        ["link"]=&gt;
        string(82) "http://feedproxy.google.com/~r/p2000-nederland/~3/OeCbBLSpOKQ/p2000-nederland.html"
        ["description"]=&gt;
        string(194) "Melding: test      Korps/Voertuig: AMBU Brabant Noord (Den Bosch-Ambu 21-102)      Capcode: 1121020&lt;img src="http://feeds.feedburner.com/~r/p2000-nederland/~4/OeCbBLSpOKQ" height="1" width="1"/&gt;"
        ["pubDate"]=&gt;
        string(31) "Mon, 10 Sep 2012 22:20:08 +0000"
        ["guid"]=&gt;
        string(25) "10-09-12_22:20.08_1121020"
      }
      [1]=&gt;
      object(SimpleXMLElement)#23 (5) {
        ["title"]=&gt;
        string(18) "contact supervisor"
        ["link"]=&gt;
        string(82) "http://feedproxy.google.com/~r/p2000-nederland/~3/OeCbBLSpOKQ/p2000-nederland.html"
        ["description"]=&gt;
        string(197) "Melding: contact supervisor      Korps/Voertuig: regio 15 Haaglanden POLITIE 10       Capcode: 1530710&lt;img src="http://feeds.feedburner.com/~r/p2000-nederland/~4/OeCbBLSpOKQ" height="1" width="1"/&gt;"
        ["pubDate"]=&gt;
        string(31) "Mon, 10 Sep 2012 22:19:28 +0000"
        ["guid"]=&gt;
        string(25) "10-09-12_22:19.28_1530710"
      }
  </code></pre>
  
  <p>So it needs to fix unique strings at: <code>$Object-&gt;item[1]-&gt;title</code></p>