title: Convert multidimensional objects to array
body: <p>I'm using amazon product advertising api. Values are returned as a multidimensional objects.</p>
  
  <p>It looks like this:</p>
  
  <pre><code>object(AmazonProduct_Result)#222 (5) {
    ["_code":protected]=&gt;
    int(200)
    ["_data":protected]=&gt;
    string(16538) 
  array(2) {
      ["IsValid"]=&gt;
      string(4) "True"
      ["Items"]=&gt;
      array(1) {
        [0]=&gt;
        object(AmazonProduct_Item)#19 (1) {
          ["_values":protected]=&gt;
          array(11) {
            ["ASIN"]=&gt;
            string(10) "B005HNF01O"
            ["ParentASIN"]=&gt;
            string(10) "B008RKEIZ8"
            ["DetailPageURL"]=&gt;
            string(120) "http://www.amazon.com/Case-Logic-TBC-302-FFP-Compact/dp/B005HNF01O?SubscriptionId=AKIAJNFRQCIJLTY6LDTA&amp;tag=*********-20"
            ["ItemLinks"]=&gt;
            array(7) {
              [0]=&gt;
              object(AmazonProduct_ItemLink)#18 (1) {
                ["_values":protected]=&gt;
                array(2) {
                  ["Description"]=&gt;
                  string(17) "Technical Details"
                  ["URL"]=&gt;
                  string(217) "http://www.amazon.com/Case-Logic-TBC-302-FFP-Compact/dp/tech-data/B005HNF01O%3FSubscriptionId%3DAKIAJNFRQCIJLTY6LDTA%26tag%*******-20%26linkCode%3Dxm2%26camp%3D2025%26creative%3D386001%26creativeASIN%3DB005HNF01O"
                }
              }
              [1]=&gt;
              object(AmazonProduct_ItemLink)#17 (1) {
                ["_values":protected]=&gt;
                array(2) {
  </code></pre>
  
  <p>I mean it also has array inside objects. I would like to convert all of them into a multidimensional array.</p>