I have a multi-dimensional associative array like this one:
array (size=2)
  'a' => 
    array (size=3)
      'b' => string 'this' (length=4)
      'c' => string 'is' (length=2)
      'd' => string 'a test' (length=6)
  'c' => 
    array (size=4)
      0 => int 1
      1 => int 2
      2 => int 3
      3 => 
        array (size=1)
          'd' => string '123' (length=3)
I try to flatten it to a single-dimensional associative array with the treepath as keys:
array (size=7)
  'a>b' => string 'this' (length=4)
  'a>c' => string 'is' (length=2)
  'a>d' => string 'a test' (length=6)
  'c>0' => string '1' (length=1)
  'c>1' => string '2' (length=1)
  'c>2' => string '3' (length=1)
  'c>3>d' => string '123' (length=3)
See my attempt here: http://codepad.org/MGaBPpZP