src/DataFilter/Util.php
public static function flatten($data, $flat = array(), $prefix = '')
    {
        foreach ($data as $key => $value) {

            // is array -> flatten deeped
            if (is_array($value)) {
                $flat = self::flatten($value, $flat, $prefix. $key. self::$FLATTEN_SEPARATOR);
            }
            // scalar -> use
            else {
                $flat[$prefix. $key] = $value;
            }
        }
        return $flat;
    }
public static function flatten($data, $flat = array(), $prefix = '')
    {
        foreach ($data as $key => $value) {

            // is array -> flatten deeped
            if (is_array($value)) {
                $flat = self::flatten($value, $flat, $prefix. $key. self::$FLATTEN_SEPARATOR);
            }
            // scalar -> use
            else {
                $flat[$prefix. $key] = $value;
            }
        }
        return $flat;
    }
public static function flatten ( $ data , $ flat = array ( ) , $ prefix = '' ) { foreach ( $ data as $ key => $ value ) { // is array -> flatten deeped if ( is_array ( $ value ) ) { $ flat = self :: flatten ( $ value , $ flat , $ prefix . $ key . self :: $ FLATTEN_SEPARATOR ) ; } // scalar -> use else { $ flat [ $ prefix . $ key ] = $ value ; } } return $ flat ; }
Flattens input data

@param string  $str   Input string
@param array   $args  Variables to be replaced

@return array
Flattens input data