public static function arrayUnshiftAssoc(&$arr, $key, $val)
    {
        $arr = array_reverse($arr, true);
        $arr[$key] = $val;
        return array_reverse($arr, true);
    }
public static function arrayUnshiftAssoc(&$arr, $key, $val)
    {
        $arr = array_reverse($arr, true);
        $arr[$key] = $val;
        return array_reverse($arr, true);
    }
public static function arrayUnshiftAssoc ( & $ arr , $ key , $ val ) { $ arr = array_reverse ( $ arr , true ) ; $ arr [ $ key ] = $ val ; return array_reverse ( $ arr , true ) ; }
Prepend an assoc array item as first entry for a given array.

@param array $arr The array where the value should be prepend
@param string $key The new array key
@param mixed $val The value for the new key
@return array
Prepend an assoc array item as first entry for a given array .