private function merge($existing, $incoming)
	{
		foreach ($incoming as $k => $v)
		{
			if (is_array($v))
			{
				$existing[$k] = isset($existing[$k]) ? $this->merge($existing[$k], $v) : $this->merge(array(), $v);
			}
			else
			{
				if (is_numeric($k))
				{
					$existing[] = $v;
				}
				else
				{
					$existing[$k] = $v;
				}
			}
		}

		return $existing;
	}
private function merge($existing, $incoming)
	{
		foreach ($incoming as $k => $v)
		{
			if (is_array($v))
			{
				$existing[$k] = isset($existing[$k]) ? $this->merge($existing[$k], $v) : $this->merge(array(), $v);
			}
			else
			{
				if (is_numeric($k))
				{
					$existing[] = $v;
				}
				else
				{
					$existing[$k] = $v;
				}
			}
		}

		return $existing;
	}
private function merge ( $ existing , $ incoming ) { foreach ( $ incoming as $ k => $ v ) { if ( is_array ( $ v ) ) { $ existing [ $ k ] = isset ( $ existing [ $ k ] ) ? $ this -> merge ( $ existing [ $ k ] , $ v ) : $ this -> merge ( array ( ) , $ v ) ; } else { if ( is_numeric ( $ k ) ) { $ existing [ ] = $ v ; } else { $ existing [ $ k ] = $ v ; } } } return $ existing ; }
Merge multiple arrays into one, recursively

Dear future developer who comes in and says, "Why, there's a PHP function for that!
It's called array_merge_recursive".  Don't do it!  This function works slightly
differently.  Namely, if a nested array is not associative, we want it to append items
to it, rather than completely overwrite the value of the nested element.

@param   array  $existing  The existing data
@param   array  $incoming  The new data
@return  array
Merge multiple arrays into one recursively