All pastes #74095 Raw Edit

Renich

public php v1 · immutable
#74095 ·published 2006-06-28 17:39 UTC
rendered paste body
function sort_array($array){	if ( is_array($array) ) {		foreach ($array as $key => $data)		{			// Sort the rest of the levels by key			if ( is_array($data) ) {				// Sort the arrays inside the array				// ksort($array[$key]);				// Get recursive, baby!				$array[$key] = sort_array($array[$key]);			} else {			}		}	}	// Sort this level	asort($array);	ksort($array);	// Regresar datos ordenados	return $array;}